Database: card_games
Question: What are the cards that only available in paper and Japanese language?
Evidence: available in paper refers to availability = 'paper'; 'Japanese is the language;
SQL: SELECT T1.name FROM cards AS T1 INNER JOIN foreign_data AS T2 ON T1.uuid = T2.uuid WHERE T1.availability = 'paper' AND T2.language = 'Japanese'

Database: california_schools
Question: Which school in Contra Costa has the highest number of test takers?
SQL: SELECT sname FROM satscores WHERE cname = 'Contra Costa' AND sname IS NOT NULL ORDER BY NumTstTakr DESC LIMIT 1

Database: codebase_community
Question: For the user No.24, how many times is the number of his/her posts compared to his/her votes?
Evidence: user no. 24 refers to UserId = OwnerUserId = '24'; times of his/her post than votes = Divide (Count(post.Id), Count(votes.Id))
SQL: SELECT CAST(COUNT(T2.Id) AS REAL) / COUNT(DISTINCT T1.Id) FROM votes AS T1 INNER JOIN posts AS T2 ON T1.UserId = T2.OwnerUserId WHERE T1.UserId = 24

Database: european_football_2
Question: How many players were born after 1990?
Evidence: born after 1990 refers to strftime('%Y', birthday) = '1990';
SQL: SELECT COUNT(id) FROM Player WHERE STRFTIME('%Y', birthday) > '1990'

Database: formula_1
Question: List the driver's ID of the top five driver, by descending order, the fastest time during the first lap of the race.
Evidence: fastest time refers to Min(time);
SQL: SELECT driverId FROM lapTimes WHERE lap = 1 ORDER BY time LIMIT 5

Database: student_club
Question: State the date Connor Hilton paid his/her dues.
Evidence: Connor Hilton is the full name; full name refers to first_name, last_name; date the dues was paid refers to date_received where source = 'Dues';
SQL: SELECT T2.date_received FROM member AS T1 INNER JOIN income AS T2 ON T1.member_id = T2.link_to_member WHERE T1.first_name = 'Connor' AND T1.last_name = 'Hilton' AND T2.source = 'Dues'

Database: formula_1
Question: What is the average fastest lap time in seconds for Lewis Hamilton in all the Formula_1 races?
Evidence: average fastest lap time = avg(fastestLapTime); The time is recorded on 'MM:SS.mmm'
SQL: SELECT AVG(CAST(SUBSTR(T2.fastestLapTime, 1, INSTR(T2.fastestLapTime, ':') - 1) AS INTEGER) * 60 + CAST(SUBSTR(T2.fastestLapTime, INSTR(T2.fastestLapTime, ':') + 1) AS REAL)) FROM drivers AS T1 INNER JOIN results AS T2 ON T1.driverId = T2.driverId WHERE T1.surname = 'Hamilton' AND T1.forename = 'Lewis'

Database: formula_1
Question: Please list the location coordinates of the circuits whose lap record is 1:29.488.
Evidence: lap records means the fastest time recorded which refers to time; coordinates are expressed as latitude and longitude which refers to (lat, lng)
SQL: SELECT T3.lat, T3.lng FROM lapTimes AS T1 INNER JOIN races AS T2 on T1.raceId = T2.raceId INNER JOIN circuits AS T3 on T2.circuitId = T3.circuitId WHERE T1.time = '1:29.488'

Database: california_schools
Question: What is the total number of non-chartered schools in the county of Los Angeles with a percent (%) of eligible free meals for grades 1 through 12 that is less than 0.18%?
Evidence: non-chartered schools refer to schools whose Charter = 0; K-12 means grades 1 through 12; percent of eligible free rate for K-12 = `Free Meal Count (K-12)` * 100 / `Enrollment (K-12)`
SQL: SELECT COUNT(T2.School) FROM frpm AS T1 INNER JOIN schools AS T2 ON T1.CDSCode = T2.CDSCode WHERE T2.County = 'Los Angeles' AND T2.Charter = 0 AND CAST(T1.`Free Meal Count (K-12)` AS REAL) * 100 / T1.`Enrollment (K-12)` < 0.18

Database: codebase_community
Question: How many posts by Matt Parker have more than 4 votes?
Evidence: more than 4 votes refer to PostId > 4; DisplayName = 'Matt Parker';
SQL: SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN postHistory AS T2 ON T1.Id = T2.UserId INNER JOIN posts AS T3 ON T2.PostId = T3.Id INNER JOIN votes AS T4 ON T4.PostId = T3.Id WHERE T1.DisplayName = 'Matt Parker' GROUP BY T2.PostId, T4.Id HAVING COUNT(T4.Id) > 4

Database: toxicology
Question: What proportion of single bonds are carcinogenic? Please provide your answer as a percentage with five decimal places.
Evidence: single bond refers to bond_type = '-'; label = '+' mean molecules are carcinogenic; proportion = DIVIDE(SUM(label = '+') * 100, COUNT(bond_id)) where bond_type = '-'
SQL: SELECT ROUND(CAST(COUNT(CASE WHEN T2.label = '+' THEN T1.bond_id ELSE NULL END) AS REAL) * 100 / COUNT(T1.bond_id),5) FROM bond AS T1 INNER JOIN molecule AS T2 ON T1.molecule_id = T2.molecule_id WHERE T1.bond_type = '-'

Database: financial
Question: Provide the IDs and age of the client with high level credit card, which is eligible for loans.
Evidence: the credit card is high-level refers to card.type = 'gold'; eligible for loans refers to disp.type = 'OWNER'
SQL: SELECT T1.client_id, STRFTIME('%Y', CURRENT_TIMESTAMP) - STRFTIME('%Y', T3.birth_date) FROM disp AS T1 INNER JOIN card AS T2 ON T2.disp_id = T1.disp_id INNER JOIN client AS T3 ON T1.client_id = T3.client_id WHERE T2.type = 'gold' AND T1.type = 'OWNER'

Database: formula_1
Question: Which constructor scored most points from Monaco Grand Prix between 1980 and 2010? List the score, name and nationality of this team.
Evidence: Monaco Grand Priz refers to the race; race in year between 1980 and 2010
SQL: SELECT SUM(T1.points), T2.name, T2.nationality FROM constructorResults AS T1 INNER JOIN constructors AS T2 ON T1.constructorId = T2.constructorId INNER JOIN races AS T3 ON T3.raceid = T1.raceid WHERE T3.name = 'Monaco Grand Prix' AND T3.year BETWEEN 1980 AND 2010 GROUP BY T2.name ORDER BY SUM(T1.points) DESC LIMIT 1

Database: formula_1
Question: State code numbers of top 3 yougest drivers. How many Netherlandic drivers among them?
Evidence: youngest driver refers to Max (year(dob)); Netherlandic and Dutch refer to the same country
SQL: SELECT COUNT(*) FROM ( SELECT T1.nationality FROM drivers AS T1 ORDER BY JULIANDAY(T1.dob) DESC LIMIT 3) AS T3 WHERE T3.nationality = 'Dutch'

Database: student_club
Question: Please list the event names of all the events attended by Maya Mclean.
SQL: SELECT T1.event_name FROM event AS T1 INNER JOIN attendance AS T2 ON T1.event_id = T2.link_to_event INNER JOIN member AS T3 ON T2.link_to_member = T3.member_id WHERE T3.first_name = 'Maya' AND T3.last_name = 'Mclean'

Database: card_games
Question: Indicates the number of cards with pre-modern format, ruling text "This is a triggered mana ability." that do not have multiple faces.
Evidence: pre-modern format refers to format = 'premodern' ;do not have multiple faces refers to side IS NULL
SQL: SELECT COUNT(T1.id) FROM cards AS T1 INNER JOIN legalities AS T2 ON T1.uuid = T2.uuid INNER JOIN rulings AS T3 ON T1.uuid = T3.uuid WHERE T2.format = 'premodern' AND T3.text = 'This is a triggered mana ability.' AND T1.Side IS NULL

Database: california_schools
Question: What is the average writing score of the school who has the highest number of test takers whose total SAT sscores are greater or equal to 1500? Indicate the city to where the school is situated.
SQL: SELECT T1.AvgScrWrite, T2.City FROM satscores AS T1 INNER JOIN schools AS T2 ON T1.cds = T2.CDSCode ORDER BY T1.NumGE1500 DESC LIMIT 1

Database: financial
Question: Which district has the most accounts with loan contracts finished with no problems?
Evidence: status = 'A' refers to loan contracts finished with no problems
SQL: SELECT T1.A2 FROM District AS T1 INNER JOIN Account AS T2 ON T1.District_id = T2.District_id INNER JOIN Loan AS T3 ON T2.Account_id = T3.Account_id WHERE T3.status = 'A' GROUP BY T1.District_id ORDER BY COUNT(T2.Account_id) DESC LIMIT 1

Database: codebase_community
Question: How many elders obtained the "Supporter" badge?
Evidence: "Supporter" is the Name of badge;  elders refers to Age > 65
SQL: SELECT COUNT(T1.Id) FROM users AS T1 INNER JOIN badges AS T2 ON T1.Id = T2.UserId WHERE T1.Age > 65 AND T2.Name = 'Supporter'