text stringlengths 310 1.28k |
|---|
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "performance_and_rankings_timeline" (
"2005_06" text,
"2006_07" text,
"2007_08" text,
"2008_09" text,
"2009_10" text,
"2010_11" text,
"2011_12" text,
"2012_13" text
);
Question: Which 2007/ 08 has a 2011/ 12 of ur?
<|assistant|>
SELECT "2007_08" FROM "performance_and_rankings_timeline" WHERE "2011_12"='ur';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: What was the Attendance on September 11, 1983?
<|assistant|>
SELECT "attendance" FROM "schedule" WHERE "date"='september 11, 1983';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: What was the Opponent during the game with a Result of W 37-21?
<|assistant|>
SELECT "opponent" FROM "schedule" WHERE "result"='w 37-21';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "schedule" (
"week" real,
"date" text,
"opponent" text,
"result" text,
"attendance" real
);
Question: What was the Result on Week 8?
<|assistant|>
SELECT "result" FROM "schedule" WHERE "week"=8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "world_championship_group_d_belgium" (
"games" real,
"drawn" real,
"lost" real,
"points_difference" text,
"points" real
);
Question: What is the lowest number of games with less than 1 loss?
<|assistant|>
SELECT MIN("games") FROM "world_championship_group_d_belgium" WHERE "lost"<1;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "men" (
"rank" real,
"name" text,
"club" text,
"nation" text,
"points" real
);
Question: What was the nationality of the skater with 108.8 points?
<|assistant|>
SELECT "nation" FROM "men" WHERE "points"=108.8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "men" (
"rank" real,
"name" text,
"club" text,
"nation" text,
"points" real
);
Question: How many points for the skater from club btsc?
<|assistant|>
SELECT COUNT("points") FROM "men" WHERE "club"='btsc';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "films_directed_by_tarkovsky" (
"year" real,
"english_title" text,
"original_title" text,
"country" text,
"length" text
);
Question: Which Original title has a Year of 1983, and a Country of italy?
<|assistant|>
SELECT "original_title" FROM "films_directed_by_tarkovsky" WHERE "year"=1983 AND "country"='italy';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "films_directed_by_tarkovsky" (
"year" real,
"english_title" text,
"original_title" text,
"country" text,
"length" text
);
Question: How many years have an Original title of ΠΈΠ²Π°Π½ΠΎΠ²ΠΎ Π΄Π΅ΡΡΡΠ²ΠΎ?
<|assistant|>
SELECT COUNT("year") FROM "films_directed_by_tarkovsky" WHERE "original_title"='ΠΈΠ²Π°Π½ΠΎΠ²ΠΎ Π΄Π΅ΡΡΡΠ²ΠΎ';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "films_directed_by_tarkovsky" (
"year" real,
"english_title" text,
"original_title" text,
"country" text,
"length" text
);
Question: Which Length has a Country of soviet union, and a Year larger than 1975?
<|assistant|>
SELECT "length" FROM "films_directed_by_tarkovsky" WHERE "country"='soviet union' AND "year">1975;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
Question: What is listed as the lowest Year with a Wins that's smaller than 0?
<|assistant|>
SELECT MIN("year") FROM "motorcycle_grand_prix_results" WHERE "wins"<0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
Question: What is listed for the Wins with a Year of 1989?
<|assistant|>
SELECT "wins" FROM "motorcycle_grand_prix_results" WHERE "year"=1989;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "motorcycle_grand_prix_results" (
"year" real,
"class" text,
"team" text,
"points" real,
"wins" real
);
Question: What is listed for the Class that's got a Team of Cagiva and Points of 4?
<|assistant|>
SELECT "class" FROM "motorcycle_grand_prix_results" WHERE "team"='cagiva' AND "points"=4;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "population" (
"district" text,
"district_headquarters" text,
"area_km_2" real,
"population_1991_census" real,
"population_2001_census" real
);
Question: How many km2 has a Population 2001 Census larger than 274,095, and a District Headquarters of jharsuguda?
<|assistant|>
SELECT COUNT("area_km_2") FROM "population" WHERE "population_2001_census">'274,095' AND "district_headquarters"='jharsuguda';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "population" (
"district" text,
"district_headquarters" text,
"area_km_2" real,
"population_1991_census" real,
"population_2001_census" real
);
Question: What is the number of Population 2001 Census that has 476,815 in Population 1991 Census?
<|assistant|>
SELECT SUM("population_2001_census") FROM "population" WHERE "population_1991_census"='476,815';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "population" (
"district" text,
"district_headquarters" text,
"area_km_2" real,
"population_1991_census" real,
"population_2001_census" real
);
Question: What is the number of Population 2001 Census that has jharsuguda District Headquarters with an Area smaller than 2,081?
<|assistant|>
SELECT COUNT("population_2001_census") FROM "population" WHERE "district_headquarters"='jharsuguda' AND "area_km_2"<'2,081';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What played has 3 as the losing bonus?
<|assistant|>
SELECT "played" FROM "2011_2012_table" WHERE "losing_bonus"='3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What is the try bonus that has llangefni rfc as the club?
<|assistant|>
SELECT "try_bonus" FROM "2011_2012_table" WHERE "club"='llangefni rfc';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What played has 247 as the points?
<|assistant|>
SELECT "played" FROM "2011_2012_table" WHERE "points_for"='247';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What try bonus has 19 as the tries against?
<|assistant|>
SELECT "try_bonus" FROM "2011_2012_table" WHERE "tries_against"='19';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What points has 18 for the played and bala rfc as the club?
<|assistant|>
SELECT "points_for" FROM "2011_2012_table" WHERE "played"='18' AND "club"='bala rfc';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "2011_2012_table" (
"club" text,
"played" text,
"drawn" text,
"lost" text,
"points_for" text,
"points_against" text,
"tries_for" text,
"tries_against" text,
"try_bonus" text,
"losing_bonus" text
);
Question: What try bonus has 18 as the played of and 204 as the points?
<|assistant|>
SELECT "try_bonus" FROM "2011_2012_table" WHERE "played"='18' AND "points_for"='204';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What record has montreal as the visitor, and february 2 as the date?
<|assistant|>
SELECT "record" FROM "game_log" WHERE "visitor"='montreal' AND "date"='february 2';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What record has February 25 as the date?
<|assistant|>
SELECT "record" FROM "game_log" WHERE "date"='february 25';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What date has boston as the visitor?
<|assistant|>
SELECT "date" FROM "game_log" WHERE "visitor"='boston';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What score has vancouver as the home, and february 16 as the date?
<|assistant|>
SELECT "score" FROM "game_log" WHERE "home"='vancouver' AND "date"='february 16';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
Question: Team of corinthians, and a Lost larger than 15 has which highest drawn?
<|assistant|>
SELECT MAX("drawn") FROM "campeonato_brasileiro_s_rie_a" WHERE "team"='corinthians' AND "lost">15;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
Question: Difference of - 20, and a Position smaller than 17 is the highest against?
<|assistant|>
SELECT MAX("against") FROM "campeonato_brasileiro_s_rie_a" WHERE "difference"='- 20' AND "position"<17;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "campeonato_brasileiro_s_rie_a" (
"position" real,
"team" text,
"points" real,
"played" real,
"drawn" real,
"lost" real,
"against" real,
"difference" text
);
Question: Against smaller than 53, and a Drawn smaller than 10, and a Played smaller than 38 has what average points?
<|assistant|>
SELECT AVG("points") FROM "campeonato_brasileiro_s_rie_a" WHERE "against"<53 AND "drawn"<10 AND "played"<38;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: Which score was for Toronto Maple Leafs at home on November 12?
<|assistant|>
SELECT "score" FROM "regular_season" WHERE "home"='toronto maple leafs' AND "date"='november 12';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: Which home team had a visitor of Chicago Black Hawks with a score of 2β3?
<|assistant|>
SELECT "home" FROM "regular_season" WHERE "visitor"='chicago black hawks' AND "score"='2β3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: Who was home on November 26?
<|assistant|>
SELECT "home" FROM "regular_season" WHERE "date"='november 26';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the visitor with a record of 5β8β4?
<|assistant|>
SELECT "visitor" FROM "regular_season" WHERE "record"='5β8β4';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "league_table" (
"rank" real,
"name" text,
"point" real,
"played" real,
"draw" real,
"lose" real,
"goal_in" real,
"goal_loss" real,
"goal_diff" real
);
Question: What was the average rank of a player with more than 52 points, fewer than 10 draws, a goal loss under 44, and a loss under 15?
<|assistant|>
SELECT AVG("rank") FROM "league_table" WHERE "point">52 AND "draw"<10 AND "goal_loss"<44 AND "lose"<15;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "league_table" (
"rank" real,
"name" text,
"point" real,
"played" real,
"draw" real,
"lose" real,
"goal_in" real,
"goal_loss" real,
"goal_diff" real
);
Question: What was the highest number of lose for a player named Santos with more than 45 points?
<|assistant|>
SELECT MAX("lose") FROM "league_table" WHERE "name"='santos' AND "point">45;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pre_season_cup_group_stage" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"crowd" text,
"report" text
);
Question: What report has a score of 0-0 with Sydney FC?
<|assistant|>
SELECT "report" FROM "pre_season_cup_group_stage" WHERE "score"='0-0' AND "away_team"='sydney fc';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pre_season_cup_group_stage" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"crowd" text,
"report" text
);
Question: On what date was the score 0-0?
<|assistant|>
SELECT "date" FROM "pre_season_cup_group_stage" WHERE "score"='0-0';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pre_season_cup_group_stage" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"crowd" text,
"report" text
);
Question: Which home team had the score 1-3?
<|assistant|>
SELECT "home_team" FROM "pre_season_cup_group_stage" WHERE "score"='1-3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pre_season_cup_group_stage" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"crowd" text,
"report" text
);
Question: Where did the away team have round 2?
<|assistant|>
SELECT "venue" FROM "pre_season_cup_group_stage" WHERE "away_team"='round 2';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pre_season_cup_group_stage" (
"date" text,
"home_team" text,
"score" text,
"away_team" text,
"venue" text,
"crowd" text,
"report" text
);
Question: When did the venue of round 3 happen?
<|assistant|>
SELECT "date" FROM "pre_season_cup_group_stage" WHERE "venue"='round 3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "lg_as" (
"local_government_area" text,
"principal_town" text,
"land_area_km" real,
"population_2011_census" real,
"density" real
);
Question: What is the lowest density of a town with a 13,708 2011 population census ?
<|assistant|>
SELECT MIN("density") FROM "lg_as" WHERE "population_2011_census"='13,708';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: specific orbital energy of β29.8 mj/kg has what orbit?
<|assistant|>
SELECT "orbit" FROM "escape_velocities_at_altitude" WHERE "specific_orbital_energy"='β29.8 mj/kg';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: altitude above the Earth's surface of 500 to 39,900 km has what orbital period?
<|assistant|>
SELECT "orbital_period" FROM "escape_velocities_at_altitude" WHERE "altitude_above_the_earth_s_surface"='500 to 39,900 km';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: specific orbital energy of β0.5 mj/kg is what altitude above the earth's surface?
<|assistant|>
SELECT "altitude_above_the_earth_s_surface" FROM "escape_velocities_at_altitude" WHERE "specific_orbital_energy"='β0.5 mj/kg';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: Earth's surface of 357,000 to 399,000 km has what orbit altitude above?
<|assistant|>
SELECT "orbit" FROM "escape_velocities_at_altitude" WHERE "altitude_above_the_earth_s_surface"='357,000 to 399,000 km';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: Orbital period of 89 to 128 min has what specific orbital energy?
<|assistant|>
SELECT "specific_orbital_energy" FROM "escape_velocities_at_altitude" WHERE "orbital_period"='89 to 128 min';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "escape_velocities_at_altitude" (
"orbit" text,
"center_to_center_distance" text,
"altitude_above_the_earth_s_surface" text,
"orbital_period" text,
"specific_orbital_energy" text
);
Question: center-to-center distance of 6,900 to 46,300 km involves which orbital period?
<|assistant|>
SELECT "orbital_period" FROM "escape_velocities_at_altitude" WHERE "center_to_center_distance"='6,900 to 46,300 km';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "scorers" (
"player" text,
"league" real,
"malaysia_cup" real,
"fa_cup" real,
"total" real
);
Question: What was the lowest FA Cup for a Malaysia Cup of 0?
<|assistant|>
SELECT MIN("fa_cup") FROM "scorers" WHERE "malaysia_cup"<0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "scorers" (
"player" text,
"league" real,
"malaysia_cup" real,
"fa_cup" real,
"total" real
);
Question: What is Zamri Hassan's lowest Malaysia Cup when there were an FA Cup of 0?
<|assistant|>
SELECT MIN("malaysia_cup") FROM "scorers" WHERE "player"='zamri hassan' AND "fa_cup"<0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "scorers" (
"player" text,
"league" real,
"malaysia_cup" real,
"fa_cup" real,
"total" real
);
Question: What is the lowest league for the Malaysia Cup when it was larger than 0?
<|assistant|>
SELECT MIN("league") FROM "scorers" WHERE "malaysia_cup">0;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medallists_by_nation" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: How many Bronze medals did Switzerland with less than 3 Silver medals receive?
<|assistant|>
SELECT MIN("bronze") FROM "medallists_by_nation" WHERE "nation"='switzerland' AND "silver"<3;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "medallists_by_nation" (
"rank" real,
"nation" text,
"gold" real,
"silver" real,
"bronze" real,
"total" real
);
Question: What is the least amount of Silver medals that have more than 3 Bronze?
<|assistant|>
SELECT MIN("silver") FROM "medallists_by_nation" WHERE "bronze">3;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"game" real,
"march" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
Question: What is the average game for March 8 with less than 84 points?
<|assistant|>
SELECT AVG("game") FROM "regular_season" WHERE "points"<84 AND "march"=8;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "regular_season" (
"game" real,
"march" real,
"opponent" text,
"score" text,
"record" text,
"points" real
);
Question: What is the latest in March when the record of 35β16β6β3?
<|assistant|>
SELECT MAX("march") FROM "regular_season" WHERE "record"='35β16β6β3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
Question: Name the competition for score of 3-0
<|assistant|>
SELECT "competition" FROM "brazil_national_team" WHERE "score"='3-0';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
Question: Name the competition for september 10, 2008
<|assistant|>
SELECT "competition" FROM "brazil_national_team" WHERE "date"='september 10, 2008';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
Question: Name the sscore for world cup qualifying october 15, 2008
<|assistant|>
SELECT "score" FROM "brazil_national_team" WHERE "competition"='world cup qualifying' AND "date"='october 15, 2008';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
Question: Name the competition for november 19, 2008
<|assistant|>
SELECT "competition" FROM "brazil_national_team" WHERE "date"='november 19, 2008';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "brazil_national_team" (
"date" text,
"city" text,
"result" text,
"score" text,
"competition" text
);
Question: Name the date for rio de janeiro
<|assistant|>
SELECT "date" FROM "brazil_national_team" WHERE "city"='rio de janeiro';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "geography_of_students" (
"states" text,
"fall_05" real,
"fall_06" real,
"fall_07" real,
"fall_08" real,
"fall_09" real
);
Question: What number is Fall 08 from the state with 57 in Fall 06 and 74 or less in Fall 05?
<|assistant|>
SELECT COUNT("fall_08") FROM "geography_of_students" WHERE "fall_06"=57 AND "fall_05"<74;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "geography_of_students" (
"states" text,
"fall_05" real,
"fall_06" real,
"fall_07" real,
"fall_08" real,
"fall_09" real
);
Question: What number is Fall 06 from the state with 79 or less in Fall 08, 36 or greater in Fall 07 and greater than 74 in Fall 05?
<|assistant|>
SELECT AVG("fall_06") FROM "geography_of_students" WHERE "fall_08"<79 AND "fall_07">36 AND "fall_05">74;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "geography_of_students" (
"states" text,
"fall_05" real,
"fall_06" real,
"fall_07" real,
"fall_08" real,
"fall_09" real
);
Question: What number is Fall 06 from the state with 34 for Fall 09?
<|assistant|>
SELECT AVG("fall_06") FROM "geography_of_students" WHERE "fall_09"=34;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "toronto_maple_leafs_4_montreal_canadiens" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the record when the visitor was toronto maple leafs and the score was 3β10?
<|assistant|>
SELECT "record" FROM "toronto_maple_leafs_4_montreal_canadiens" WHERE "visitor"='toronto maple leafs' AND "score"='3β10';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "toronto_maple_leafs_4_montreal_canadiens" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the score when the visitor was toronto maple leafs on march 22?
<|assistant|>
SELECT "score" FROM "toronto_maple_leafs_4_montreal_canadiens" WHERE "visitor"='toronto maple leafs' AND "date"='march 22';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "toronto_maple_leafs_4_montreal_canadiens" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the Visitor when the home was toronto maple leafs and the score was 4β1?
<|assistant|>
SELECT "visitor" FROM "toronto_maple_leafs_4_montreal_canadiens" WHERE "home"='toronto maple leafs' AND "score"='4β1';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "auction_history" (
"auction_house" text,
"year" real,
"event" text,
"price" real,
"gbp_price" real
);
Question: What is the average GBP Price with an event in Monterey, a RM auction house, and a price of $154,000 later than 2003?
<|assistant|>
SELECT AVG("gbp_price") FROM "auction_history" WHERE "event"='monterey' AND "auction_house"='rm' AND "price"='154,000' AND "year">2003;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "seasonal_ratings_broadcast_history" (
"season" real,
"network" text,
"time_slot" text,
"season_premiere" text,
"season_finale" text,
"episode_count" real,
"tv_season" text,
"season_rank" text,
"viewers_in_millions" real
);
Question: How many total episodes aired over all seasons with 7.79 million viewers?
<|assistant|>
SELECT COUNT("episode_count") FROM "seasonal_ratings_broadcast_history" WHERE "viewers_in_millions"=7.79;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "manchester_and_district_challenge_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text
);
Question: Was the semi-final round held at home or away?
<|assistant|>
SELECT "h_a" FROM "manchester_and_district_challenge_cup" WHERE "round"='semi-final';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "manchester_and_district_challenge_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text
);
Question: Which opponent made it to the final round?
<|assistant|>
SELECT "opponents" FROM "manchester_and_district_challenge_cup" WHERE "round"='final';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "manchester_and_district_challenge_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text
);
Question: What was the result of the game played in hurst?
<|assistant|>
SELECT "result_f_a" FROM "manchester_and_district_challenge_cup" WHERE "h_a"='hurst';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "manchester_and_district_challenge_cup" (
"date" text,
"round" text,
"opponents" text,
"h_a" text,
"result_f_a" text
);
Question: When did the game in whalley range take place?
<|assistant|>
SELECT "date" FROM "manchester_and_district_challenge_cup" WHERE "h_a"='whalley range';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "full_powered_stations" (
"call_sign" text,
"frequency_m_hz" real,
"city_of_license" text,
"erp_w" real,
"class" text,
"fcc_info" text
);
Question: Which ERP W is the lowest one that has a Frequency MHz of 91.3?
<|assistant|>
SELECT MIN("erp_w") FROM "full_powered_stations" WHERE "frequency_m_hz"=91.3;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "full_powered_stations" (
"call_sign" text,
"frequency_m_hz" real,
"city_of_license" text,
"erp_w" real,
"class" text,
"fcc_info" text
);
Question: Which Class has a Frequency MHz of 107.5?
<|assistant|>
SELECT "class" FROM "full_powered_stations" WHERE "frequency_m_hz"=107.5;<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "full_powered_stations" (
"call_sign" text,
"frequency_m_hz" real,
"city_of_license" text,
"erp_w" real,
"class" text,
"fcc_info" text
);
Question: Which Frequency MHz is the highest one that has a City of license of byron, ga?
<|assistant|>
SELECT MAX("frequency_m_hz") FROM "full_powered_stations" WHERE "city_of_license"='byron, ga';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "full_powered_stations" (
"call_sign" text,
"frequency_m_hz" real,
"city_of_license" text,
"erp_w" real,
"class" text,
"fcc_info" text
);
Question: Which FCC info has a Call sign of wsja?
<|assistant|>
SELECT "fcc_info" FROM "full_powered_stations" WHERE "call_sign"='wsja';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: Which District has a Party of republican and a Result of lost re-election democratic gain?
<|assistant|>
SELECT "district" FROM "california" WHERE "party"='republican' AND "result"='lost re-election democratic gain';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: What is First elected that has republican Party and a Result of retired democratic gain?
<|assistant|>
SELECT "first_elected" FROM "california" WHERE "party"='republican' AND "result"='retired democratic gain';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: What is the First elected of california 3?
<|assistant|>
SELECT "first_elected" FROM "california" WHERE "district"='california 3';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: Which Incumbent has a Result of retired democratic gain?
<|assistant|>
SELECT "incumbent" FROM "california" WHERE "result"='retired democratic gain';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: Which First elected has a Incumbent of none (new seat)?
<|assistant|>
SELECT "first_elected" FROM "california" WHERE "incumbent"='none (new seat)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "california" (
"district" text,
"incumbent" text,
"party" text,
"first_elected" text,
"result" text
);
Question: What is the First elected that has a republican party and california 4?
<|assistant|>
SELECT "first_elected" FROM "california" WHERE "party"='republican' AND "district"='california 4';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "tennent_s_scottish_cup" (
"date" text,
"opponent" text,
"venue" text,
"result" text,
"attendance" real,
"scorers" text
);
Question: What was the result when Dundee was the opponent?
<|assistant|>
SELECT "result" FROM "tennent_s_scottish_cup" WHERE "opponent"='dundee';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "series_9_2009" (
"celebrity" text,
"famous_for" text,
"entered" text,
"exited" text,
"finished" text
);
Question: Who entered on day 1 and exited on day 20?
<|assistant|>
SELECT "celebrity" FROM "series_9_2009" WHERE "entered"='day 1' AND "exited"='day 20';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "series_9_2009" (
"celebrity" text,
"famous_for" text,
"entered" text,
"exited" text,
"finished" text
);
Question: When did lucy benjamin exit?
<|assistant|>
SELECT "exited" FROM "series_9_2009" WHERE "celebrity"='lucy benjamin';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "series_9_2009" (
"celebrity" text,
"famous_for" text,
"entered" text,
"exited" text,
"finished" text
);
Question: When did camilla dallerup finish?
<|assistant|>
SELECT "finished" FROM "series_9_2009" WHERE "celebrity"='camilla dallerup';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "series_9_2009" (
"celebrity" text,
"famous_for" text,
"entered" text,
"exited" text,
"finished" text
);
Question: When did kim woodburn enter?
<|assistant|>
SELECT "entered" FROM "series_9_2009" WHERE "celebrity"='kim woodburn';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "march" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the score of the game with a record of 37β26β9?
<|assistant|>
SELECT "score" FROM "march" WHERE "record"='37β26β9';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "march" (
"date" text,
"visitor" text,
"score" text,
"home" text,
"record" text
);
Question: What was the score of the game with a record of 33β25β9?
<|assistant|>
SELECT "score" FROM "march" WHERE "record"='33β25β9';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Loss of francis (4β9) has what highest attendance figure?
<|assistant|>
SELECT MAX("attendance") FROM "game_log" WHERE "loss"='francis (4β9)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Loss of de la rosa (8β8) has what average attendance?
<|assistant|>
SELECT AVG("attendance") FROM "game_log" WHERE "loss"='de la rosa (8β8)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "game_log" (
"date" text,
"opponent" text,
"score" text,
"loss" text,
"attendance" real,
"record" text
);
Question: Loss of francis (4β10) happened on what date?
<|assistant|>
SELECT "date" FROM "game_log" WHERE "loss"='francis (4β10)';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "international_goals" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
Question: What was the score on 8 September 1999?
<|assistant|>
SELECT "score" FROM "international_goals" WHERE "date"='8 september 1999';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "international_goals" (
"date" text,
"venue" text,
"score" text,
"result" text,
"competition" text
);
Question: What was the result on 16 November 2003?
<|assistant|>
SELECT "result" FROM "international_goals" WHERE "date"='16 november 2003';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Set 1 has a Set 2 of 26β24?
<|assistant|>
SELECT "set_1" FROM "pool_a" WHERE "set_2"='26β24';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Set 2 has a Date of 25 may, and a Set 3 of 21β25?
<|assistant|>
SELECT "set_2" FROM "pool_a" WHERE "date"='25 may' AND "set_3"='21β25';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Date has a Set 3 of 21β25?
<|assistant|>
SELECT "date" FROM "pool_a" WHERE "set_3"='21β25';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Set 1 has a Date of 24 may, and a Total of 57β75?
<|assistant|>
SELECT "set_1" FROM "pool_a" WHERE "date"='24 may' AND "total"='57β75';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Set 2 has a Set 1 of 25β15, and a Score of 3β0?
<|assistant|>
SELECT "set_2" FROM "pool_a" WHERE "set_1"='25β15' AND "score"='3β0';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "pool_a" (
"date" text,
"score" text,
"set_1" text,
"set_2" text,
"set_3" text,
"total" text
);
Question: Which Total has a Set 1 of 25β22?
<|assistant|>
SELECT "total" FROM "pool_a" WHERE "set_1"='25β22';<|endoftext|> |
<|system|>
You are an expert SQL query generator. Only output valid SQL.
<|user|>
### Database Schema
CREATE TABLE "season_2_2002" (
"series_ep" text,
"episode" real,
"netflix" text,
"segment_a" text,
"segment_b" text,
"segment_c" text,
"segment_d" text
);
Question: What was the segment b for Netflix s01e21?
<|assistant|>
SELECT "segment_b" FROM "season_2_2002" WHERE "netflix"='s01e21';<|endoftext|> |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.