db_id
stringlengths
4
31
SQL
stringlengths
18
1.45k
input_sequence
stringlengths
148
11k
question
stringlengths
16
325
soccer_2016
select cast(sum(case when t2.bowling_skill = ' legbreak' then 1 else 0 end) as real) * 100 / total(t1.player_id) from player as t1 inner join bowling_style as t2 on t1.bowling_skill = t2.bowling_id
Question: what percentage of players have legbreak skill? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type...
what percentage of players have legbreak skill?
soccer_2016
select count(t2.win_id) from `match` as t1 inner join win_by as t2 on t1.win_type = t2.win_id where t2.win_type = 'wickets' and t1.win_margin < 50
Question: in the matches where the winning margin is less than fifty, how many teams won by wicket? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs...
in the matches where the winning margin is less than fifty, how many teams won by wicket?
soccer_2016
select sum(case when t1.team_2 = t1.match_winner then 1 else 0 end) from `match` as t1 inner join venue as t2 on t1.venue_id = t2.venue_id where t1.team_1 = t1.toss_winner
Question: in how many venues did team 2 win the toss and lose the match? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball...
in how many venues did team 2 win the toss and lose the match?
soccer_2016
select t2.player_name, t3.country_name from season as t1 inner join player as t2 on t1.man_of_the_series = t2.player_id inner join country as t3 on t2.country_name = t3.country_id where t1.season_year = 2012
Question: which player became the man of the series in the year 2012? give the name and country of this player. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name...
which player became the man of the series in the year 2012? give the name and country of this player.
soccer_2016
select t2.venue_name from `match` as t1 inner join venue as t2 on t1.venue_id = t2.venue_id group by t2.venue_name order by count(t2.venue_id) desc limit 1
Question: give the name of the venue where the most number of matches are held. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_I...
give the name of the venue where the most number of matches are held.
soccer_2016
select t4.city_name from `match` as t1 inner join win_by as t2 on t1.win_type = t2.win_id inner join venue as t3 on t1.venue_id = t3.venue_id inner join city as t4 on t3.city_id = t4.city_id where t2.win_type = 'no result' group by t4.city_id order by count(t2.win_type) asc limit 1
Question: which city hosted the least number of no-result matches? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, E...
which city hosted the least number of no-result matches?
soccer_2016
select t2.player_name from season as t1 inner join player as t2 on t1.man_of_the_series = t2.player_id where t1.man_of_the_series > 1
Question: write the name of the player who was the man of the series more than one time. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_I...
write the name of the player who was the man of the series more than one time.
soccer_2016
select t1.player_name, t4.country_name from player as t1 inner join wicket_taken as t2 on t1.player_id = t2.fielders inner join out_type as t3 on t2.kind_out = t3.out_id inner join country as t4 on t1.country_name = t4.country_id group by t1.player_name order by count(t3.out_name) asc
Question: list the name and country of the players who got more than average catches in ascending order of the number of catches. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Ex...
list the name and country of the players who got more than average catches in ascending order of the number of catches.
soccer_2016
select cast(count(case when t1.team_1 = t1.match_winner = t1.toss_winner then 1 else 0 end) as real) * 100 / total(t1.team_1) from `match` as t1 inner join win_by as t2 on t1.win_type = t2.win_id inner join toss_decision as t3 on t1.toss_decide = t3.toss_id where t3.toss_name = 'field' and t2.win_type = 'runs'
Question: of the matches that were won by runs by team 1, what percentage have team 1 won the toss and decided to field? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, E...
of the matches that were won by runs by team 1, what percentage have team 1 won the toss and decided to field?
soccer_2016
select avg(t1.player_out) from wicket_taken as t1 inner join out_type as t2 on t1.kind_out = t2.out_id where t2.out_name = 'lbw'
Question: what is the difference in the average number of players out by lbw and runout in the matches? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_...
what is the difference in the average number of players out by lbw and runout in the matches?
soccer_2016
select distinct over_id from ball_by_ball where striker = 7
Question: identify by their id all the overs in which the player with id 7 was on strike. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_...
identify by their id all the overs in which the player with id 7 was on strike.
soccer_2016
select count(team_1) from `match` where team_1 = toss_winner and toss_decide = 2
Question: how many first teams chose to bat after winning the toss? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, ...
how many first teams chose to bat after winning the toss?
soccer_2016
select sum(case when match_date like '2010-03%' then 1 else 0 end) from `match`
Question: how many games were played in march 2010? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, E...
how many games were played in march 2010?
soccer_2016
select sum(case when dob < '1990-06-29' then 1 else 0 end) from player where player_name != 'gurkeerat singh'
Question: how many players are older than gurkeerat singh player? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ex...
how many players are older than gurkeerat singh player?
soccer_2016
select sum(case when t2.player_name = 'sr watson' then 1 else 0 end) from `match` as t1 inner join player as t2 on t1.man_of_the_match = t2.player_id
Question: how many times has sr watson been named 'man of the match'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id...
how many times has sr watson been named 'man of the match'?
soccer_2016
select t3.player_name from player_match as t1 inner join team as t2 on t1.team_id = t2.team_id inner join player as t3 on t1.player_id = t3.player_id where t2.team_name = 'delhi daredevils' group by t3.player_name order by count(t1.role_id) desc limit 1
Question: indicate the name of the most versatile players of the delhi daredevils. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Ove...
indicate the name of the most versatile players of the delhi daredevils.
soccer_2016
select t3.player_name from season as t1 inner join match as t2 on t1.man_of_the_series = t2.man_of_the_match inner join player as t3 on t2.man_of_the_match = t3.player_id group by t3.player_name order by count(t1.man_of_the_series) desc limit 1
Question: what is the name of the player who has been chosen the most times for 'man of the series'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Run...
what is the name of the player who has been chosen the most times for 'man of the series'?
soccer_2016
select t4.season_year, t4.orange_cap from player as t1 inner join player_match as t2 on t1.player_id = t2.player_id inner join match as t3 on t2.match_id = t3.match_id inner join season as t4 on t3.season_id = t4.season_id where t1.player_name = 'sp narine' group by t4.season_year, t4.orange_cap
Question: in what year did sp narine win the orange cap? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_...
in what year did sp narine win the orange cap?
soccer_2016
select t5.team_name, t1.orange_cap, t1.purple_cap from season as t1 inner join match as t2 on t1.season_id = t2.season_id inner join player_match as t3 on t2.match_id = t3.match_id inner join player as t4 on t3.player_id = t4.player_id inner join team as t5 on t3.team_id = t5.team_id group by t5.team_name, t1.orange_ca...
Question: which teams have had a player awarded the purple cap and another with the orange cap in the same season? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_N...
which teams have had a player awarded the purple cap and another with the orange cap in the same season?
soccer_2016
select t1.player_name from player as t1 inner join country as t2 on t1.country_name = t2.country_id where t2.country_name = 'zimbabwea'
Question: list all zimbabwean players. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_Runs, In...
list all zimbabwean players.
soccer_2016
select sum(case when t2.batting_hand = 'left-hand bat' then 1 else 0 end) from player as t1 inner join batting_style as t2 on t1.batting_hand = t2.batting_id
Question: how many players bat with their left hands? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id,...
how many players bat with their left hands?
soccer_2016
select sum(case when t2.win_type != 'runs' then 1 else 0 end) from `match` as t1 inner join win_by as t2 on t1.win_type = t2.win_id
Question: how many games were not won by runs? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_...
how many games were not won by runs?
soccer_2016
select t1.umpire_name from umpire as t1 inner join country as t2 on t1.umpire_country = t2.country_id where t2.country_name = 'new zealand'
Question: list the name of all new zealand umpires. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, E...
list the name of all new zealand umpires.
soccer_2016
select t3.country_name from bowling_style as t1 inner join player as t2 on t1.bowling_id = t2.bowling_skill inner join country as t3 on t2.country_name = t3.country_id where t1.bowling_skill = 'slow left-arm chinaman'
Question: in which country do most players have the 'slow left-arm chinaman' bowling style? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Matc...
in which country do most players have the 'slow left-arm chinaman' bowling style?
soccer_2016
select t1.venue_name from venue as t1 inner join match as t2 on t1.venue_id = t2.venue_id inner join team as t3 on t2.team_1 = t3.team_id where t3.team_name = 'kochi tuskers kerala' group by t1.venue_name
Question: in which venue did kochi tuskers kerala play most of their matches? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id,...
in which venue did kochi tuskers kerala play most of their matches?
soccer_2016
select count(t1.runs_scored) from batsman_scored as t1 inner join ball_by_ball as t2 on t1.match_id = t2.match_id inner join match as t3 on t2.match_id = t3.match_id inner join team as t4 on t3.team_1 = t4.team_id where t2.team_batting = 1 or t2.team_batting = 2 and t4.team_name = 'delhi daredevils'
Question: in how many games in which the batting team was the delhi daredevils were no runs scored? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs...
in how many games in which the batting team was the delhi daredevils were no runs scored?
soccer_2016
select cast(count(case when t2.win_margin < 10 then 1 else 0 end) as real) * 100 / total(t1.venue_id) from venue as t1 inner join match as t2 on t1.venue_id = t2.venue_id where t1.venue_name = 'dr dy patil sports academy'
Question: in what percentage of games played at the dr dy patil sports academy venue did the winning team win by a margin of less than 10? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_T...
in what percentage of games played at the dr dy patil sports academy venue did the winning team win by a margin of less than 10?
soccer_2016
select avg(t1.extra_runs) from extra_runs as t1 inner join extra_type as t2 on t1.extra_type_id = t2.extra_id where t2.extra_name = 'noballs'
Question: what is the average number of extra runs made as noballs? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, ...
what is the average number of extra runs made as noballs?
soccer_2016
select player_id from player order by bowling_skill desc limit 5
Question: list the player's id of the top five players, by descending order, in terms of bowling skill. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_...
list the player's id of the top five players, by descending order, in terms of bowling skill.
soccer_2016
select count(*) from player where dob < '1975-10-16' and bowling_skill < 3
Question: how many players were born before 10/16/1975, and have a bowling skill of less than 3? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs ->...
how many players were born before 10/16/1975, and have a bowling skill of less than 3?
soccer_2016
select player_name from player order by dob desc limit 1
Question: what is the name of the youngest player? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Ex...
what is the name of the youngest player?
soccer_2016
select man_of_the_series from season where 2011 < season_year < 2015
Question: tally the player ids of 'man of the series' awardees for the seasons from 2011 to 2015. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -...
tally the player ids of 'man of the series' awardees for the seasons from 2011 to 2015.
soccer_2016
select sum(runs_scored) from batsman_scored where match_id = 335988 and innings_no = 2
Question: what is the total number of runs scored by the batsmen during the 2nd inning of the match id 335988? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name....
what is the total number of runs scored by the batsmen during the 2nd inning of the match id 335988?
soccer_2016
select sum(case when runs_scored > 3 then 1 else 0 end) from batsman_scored where 335989 < match_id < 337000 and innings_no = 1 and over_id = 1 and ball_id = 1
Question: between match nos. 335989 and 337000, how many times did a batsman score more than 3 runs during over no. 1, ball no. 1, and inning no. 1 of the matches? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_...
between match nos. 335989 and 337000, how many times did a batsman score more than 3 runs during over no. 1, ball no. 1, and inning no. 1 of the matches?
soccer_2016
select t1.match_id, t1.match_date from `match` as t1 inner join venue as t2 on t1.venue_id = t2.venue_id where t2.venue_name = 'kingsmead'
Question: give me the match id and date of the matches that were held in kingsmead for three consecutive days. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name....
give me the match id and date of the matches that were held in kingsmead for three consecutive days.
soccer_2016
select sum(case when venue_name = 'ma chidambaram stadium' then 1 else 0 end) from `match` as t1 inner join venue as t2 on t1.venue_id = t2.venue_id where match_date between '2009-05-09' and '2011-08-08'
Question: how many times did the matches were held in ma chidambaram stadium from 5/9/2009 to 8/8/2011? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_...
how many times did the matches were held in ma chidambaram stadium from 5/9/2009 to 8/8/2011?
soccer_2016
select t2.venue_name, t3.city_name from `match` as t1 inner join venue as t2 on t1.venue_id = t2.venue_id inner join city as t3 on t2.city_id = t3.city_id where t1.match_id = '336005'
Question: where was the id 336005 match held? please give me the venue and the city. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, O...
where was the id 336005 match held? please give me the venue and the city.
soccer_2016
select t2.toss_name, t1.toss_decide, t1.toss_winner from `match` as t1 inner join toss_decision as t2 on t1.toss_decide = t2.toss_id where t1.match_id = '336011'
Question: which team wins the toss during the match id 336011, and can you tell me whether they decided to bat or field? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, E...
which team wins the toss during the match id 336011, and can you tell me whether they decided to bat or field?
soccer_2016
select sum(case when t1.dob < '1980-4-11' then 1 else 0 end) from player as t1 inner join country as t2 on t1.country_name = t2.country_id where t2.country_name = 'south africa'
Question: among the south african players, how many were born before 4/11/1980? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_I...
among the south african players, how many were born before 4/11/1980?
soccer_2016
select t2.player_name from bowling_style as t1 inner join player as t2 on t1.bowling_id = t2.bowling_skill where t1.bowling_skill = 'legbreak'
Question: write down the name of players whose bowling skill is legbreak. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Bal...
write down the name of players whose bowling skill is legbreak.
soccer_2016
select t1.match_date, t4.role_desc from `match` as t1 inner join player_match as t2 on t1.match_id = t2.match_id inner join player as t3 on t2.player_id = t3.player_id inner join rolee as t4 on t2.role_id = t4.role_id order by t3.dob desc limit 1
Question: when and for what role did the youngest player appear in his first match? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Ov...
when and for what role did the youngest player appear in his first match?
soccer_2016
select t1.match_id from `match` as t1 inner join player as t2 on t1.man_of_the_match = t2.player_id where t2.player_name = 'v kohli'
Question: tally the match ids in which v kohli is the 'man of the match'. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Bal...
tally the match ids in which v kohli is the 'man of the match'.
soccer_2016
select sum(case when t1.match_date between '2011%' and '2012%' then 1 else 0 end) from `match` as t1 inner join player as t2 on t2.player_id = t1.man_of_the_match inner join country as t3 on t3.country_id = t2.country_name where t3.country_name = 'australia'
Question: from 2011 to 2012, how many australian players became the 'man of the match'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id...
from 2011 to 2012, how many australian players became the 'man of the match'?
soccer_2016
select t1.player_name from player as t1 inner join season as t2 on t1.player_id = t2.man_of_the_series = t2.orange_cap
Question: who among the players won both 'man of the series' and 'orange cap' in the same season? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -...
who among the players won both 'man of the series' and 'orange cap' in the same season?
soccer_2016
select t1.match_date from `match` as t1 inner join team as t2 on t1.match_winner = t2.team_id where t2.team_name = 'sunrisers hyderabad'
Question: when did the sunrisers hyderabad win their first match? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ex...
when did the sunrisers hyderabad win their first match?
soccer_2016
select t1.umpire_name, t1.umpire_id from umpire as t1 inner join country as t2 on t1.umpire_country = t2.country_id where t2.country_name = 'england'
Question: write down the player names and ids of the english umpires. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id...
write down the player names and ids of the english umpires.
soccer_2016
select cast(count(case when t1.toss_name = 'bat' then t3.runs_scored else null end) as real) / sum(case when t1.toss_name = 'field' then 1 else 0 end) from toss_decision as t1 inner join match as t2 on t1.toss_id = t2.toss_decide inner join batsman_scored as t3 on t2.match_id = t3.match_id where t2.match_id = 335987 an...
Question: calculate the run rate at the end of 17 overs of the match id 335987 on 4/18/2008. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Mat...
calculate the run rate at the end of 17 overs of the match id 335987 on 4/18/2008.
soccer_2016
select cast(count(case when t1.toss_name = 'bat' then t3.runs_scored else null end) as real) / sum(case when t1.toss_name = 'field' then 1 else 0 end) from toss_decision as t1 inner join match as t2 on t1.toss_id = t2.toss_decide inner join batsman_scored as t3 on t2.match_id = t3.match_id where t2.match_id = 335987 an...
Question: compute the run rate at the end of 16 overs of the match id 335999. please include the name of the 'man of_the match'. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Ext...
compute the run rate at the end of 16 overs of the match id 335999. please include the name of the 'man of_the match'.
soccer_2016
select match_id from `match` order by match_winner desc limit 1
Question: what is the id of the team with the highest number of matches won? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, ...
what is the id of the team with the highest number of matches won?
soccer_2016
select dob from player group by dob order by count(dob) desc limit 1
Question: which year do the majority of the players were born? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra...
which year do the majority of the players were born?
soccer_2016
select match_date from `match` order by win_margin desc limit 1
Question: what is the date of the match that has the highest wager on the final result of a game? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -...
what is the date of the match that has the highest wager on the final result of a game?
soccer_2016
select season_id from `match` group by season_id order by count(match_id) limit 1
Question: which season has the fewest number of matches? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_...
which season has the fewest number of matches?
soccer_2016
select count(match_id) from `match` group by man_of_the_match having count(match_id) >= 5
Question: how many players have won at least 5 man of the match awards? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_...
how many players have won at least 5 man of the match awards?
soccer_2016
select t1.player_name from player as t1 inner join match as t2 on t1.player_id = t2.man_of_the_match where t2.season_id = 9 order by t2.match_date desc limit 1
Question: who is the player who received the man of the match award during the last match of season 9? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_R...
who is the player who received the man of the match award during the last match of season 9?
soccer_2016
select t1.team_name from team as t1 inner join match as t2 on t1.team_id = t2.match_winner where t2.season_id = 1 order by t2.match_date limit 1
Question: what is the name of the team that won the first ever match? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id...
what is the name of the team that won the first ever match?
soccer_2016
select sum(case when t2.country_name = 'u.a.e' then 1 else 0 end) from city as t1 inner join country as t2 on t1.country_id = t2.country_id
Question: how many cities are in u.a.e? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_Runs, I...
how many cities are in u.a.e?
soccer_2016
select t1.umpire_name from umpire as t1 inner join country as t2 on t2.country_id = t1.umpire_country where t2.country_name = 'england'
Question: list the names of all the umpires from england. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type...
list the names of all the umpires from england.
soccer_2016
select t1.player_name from player as t1 inner join bowling_style as t2 on t1.bowling_skill = t2.bowling_id where t2.bowling_skill = 'legbreak'
Question: how many players bowl in the legbreak style? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id...
how many players bowl in the legbreak style?
soccer_2016
select sum(case when t1.season_id = 8 then 1 else 0 end) from `match` as t1 inner join team as t2 on t1.team_1 = t2.team_id or t1.team_2 = t2.team_id where t2.team_name = 'rajasthan royals'
Question: how many matches did rajasthan royals play in season 8? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ex...
how many matches did rajasthan royals play in season 8?
soccer_2016
select t2.country_name from umpire as t1 inner join country as t2 on t2.country_id = t1.umpire_country where t1.umpire_name = 'th wijewardene'
Question: which country is umpire th wijewardene from? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id...
which country is umpire th wijewardene from?
soccer_2016
select t1.venue_name from venue as t1 inner join city as t2 on t1.city_id = t2.city_id where t2.city_name = 'abu dhabi'
Question: what are the names of the venues in abu dhabi? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_...
what are the names of the venues in abu dhabi?
soccer_2016
select t1.country_name from country as t1 inner join player as t2 on t1.country_id = t2.country_name order by t2.dob desc limit 1
Question: which country is the youngest player from? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, ...
which country is the youngest player from?
soccer_2016
select t3.player_name from `match` as t1 inner join player_match as t2 on t1.match_winner = t2.team_id inner join player as t3 on t2.player_id = t3.player_id where t1.season_id = 1 order by t1.match_date limit 1
Question: list all the names of the winning team's players in the first match of season 1. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match...
list all the names of the winning team's players in the first match of season 1.
soccer_2016
select t1.player_name from player as t1 inner join season as t2 on t1.player_id = t2.purple_cap order by t2.season_year - substr(t1.dob, 1, 4) limit 1
Question: who is the youngest player to have won the purple cap? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ext...
who is the youngest player to have won the purple cap?
soccer_2016
select t1.venue_name, t2.city_name, t3.country_name from venue as t1 inner join city as t2 on t1.city_id = t2.city_id inner join country as t3 on t2.country_id = t3.country_id inner join match as t4 on t1.venue_id = t4.venue_id order by t4.match_date desc limit 1
Question: provide the complete name of the venue, city and country where the last match was held. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -...
provide the complete name of the venue, city and country where the last match was held.
soccer_2016
select sum(case when innings_no = 1 then 1 else 0 end) as in1 , sum(case when innings_no = 2 then 1 else 0 end) as in2 from ball_by_ball where match_id = 336011
Question: how many overs were there in each innings of match id '336011'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Bal...
how many overs were there in each innings of match id '336011'?
soccer_2016
select ball_id, runs_scored, innings_no from batsman_scored where match_id = 335988 and over_id = 20
Question: list the ball ids, scores, and innings numbers in the over id 20 of match id '335988'. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs ->...
list the ball ids, scores, and innings numbers in the over id 20 of match id '335988'.
soccer_2016
select count(match_id) from `match` where match_date like '2011%'
Question: how many matches were held in 2011? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_R...
how many matches were held in 2011?
soccer_2016
select 2022 - substr(dob, 1, 4) from player where player_name = 'ishan kishan'
Question: how old is ishan kishan in 2022? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_Runs...
how old is ishan kishan in 2022?
soccer_2016
select cast(sum(case when toss_winner = match_winner then 1 else 0 end) as real) / sum(case when match_date like '2012%' then 1 else 0 end) from `match`
Question: calculate the win rate of the toss-winners in 2012. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_...
calculate the win rate of the toss-winners in 2012.
soccer_2016
select count(match_id) from `match` where match_date like '2009%' and win_margin < 10
Question: how many matches in 2009 had win margins of less than 10? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, ...
how many matches in 2009 had win margins of less than 10?
soccer_2016
select t1.player_name from player as t1 inner join player_match as t2 on t1.player_id = t2.player_id inner join match as t3 on t2.match_id = t3.match_id where substr(t3.match_date, 1, 4) = '2014' and substr(t3.match_date, 7, 1) = '6' limit 2
Question: provide the players' names in both teams of the match that was held in june 2014. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Matc...
provide the players' names in both teams of the match that was held in june 2014.
soccer_2016
select sum(case when t2.player_name = 'mohammad hafeez' then 1 else 0 end) from player_match as t1 inner join player as t2 on t1.player_id = t2.player_id
Question: how many matches did mohammad hafeez play? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, ...
how many matches did mohammad hafeez play?
soccer_2016
select t1.player_name from player as t1 inner join country as t2 on t1.country_name = t2.country_id where t2.country_name = 'south africa' and t1.dob like '1984%'
Question: among the players from south africa, provide the players' names who were born in 1984. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs ->...
among the players from south africa, provide the players' names who were born in 1984.
soccer_2016
select cast(sum(case when t1.match_winner = t2.team_id then 1 else 0 end) as real) * 100 / count(t1.match_id) from `match` as t1 inner join team as t2 on t1.team_1 = t2.team_id or t1.team_2 = t2.team_id where t2.team_name = 'mumbai indians' and t1.match_date like '2009%'
Question: among the' mumbai indians' team that played in 2009, how many percent of the matches did they win? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. E...
among the' mumbai indians' team that played in 2009, how many percent of the matches did they win?
soccer_2016
select cast(sum(case when t2.batting_hand = 'left-hand bat' then 1 else 0 end) as real) / sum(case when t2.batting_hand = 'right-hand bat' then 1 else 0 end) from player as t1 inner join batting_style as t2 on t1.batting_hand = t2.batting_id
Question: what is the ratio of players with batting hands of left and right? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, ...
what is the ratio of players with batting hands of left and right?
soccer_2016
select t1.player_name, t2.country_name from player as t1 inner join country as t2 on t1.country_name = t2.country_id order by t1.dob limit 1
Question: who is the eldest player and where did he/she come from? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, E...
who is the eldest player and where did he/she come from?
soccer_2016
select t1.bowling_skill from bowling_style as t1 inner join player as t2 on t1.bowling_id = t2.bowling_skill inner join country as t3 on t2.country_name = t3.country_id where t3.country_name = 'zimbabwea'
Question: which bowling skills did the players from zimbabwea have? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, ...
which bowling skills did the players from zimbabwea have?
soccer_2016
select t1.umpire_id, t1.umpire_name from umpire as t1 inner join country as t2 on t1.umpire_country = t2.country_id where t2.country_name = 'new zealand'
Question: list the ids and names of the umpires from new zealand. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ex...
list the ids and names of the umpires from new zealand.
soccer_2016
select t1.player_name from player as t1 inner join player_match as t2 on t1.player_id = t2.player_id inner join team as t3 on t2.team_id = t3.team_id inner join rolee as t4 on t2.role_id = t4.role_id where t3.team_name = 'rising pune supergiants' and t4.role_desc = 'captainkeeper' group by t1.player_name
Question: who was the captain-keeper of rising pune supergiants? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ext...
who was the captain-keeper of rising pune supergiants?
soccer_2016
select sum(case when match_date like '2013%' then 1 else 0 end) from `match` as t1 inner join team as t2 on t1.match_winner = t2.team_id where t2.team_name = 'sunrisers hyderabad'
Question: how many matches did the sunrisers hyderabad team win in 2013? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball...
how many matches did the sunrisers hyderabad team win in 2013?
soccer_2016
select t1.match_id from extra_runs as t1 inner join extra_type as t2 on t1.extra_type_id = t2.extra_id where t2.extra_name = 'penalty'
Question: provide match id which had the extra type of penalty. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extr...
provide match id which had the extra type of penalty.
soccer_2016
select t1.team_name from team as t1 inner join match as t2 on t1.team_id = t2.team_1 or t1.team_id = t2.team_2 inner join win_by as t3 on t2.win_type = t3.win_id where substr(t2.match_date, 1, 4) = '2015' and t3.win_type = 'tie' limit 1
Question: name the teams played in a match which resulted in a tie in 2015. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, B...
name the teams played in a match which resulted in a tie in 2015.
soccer_2016
select cast(count(t1.player_out) as real) / count(t1.match_id), sum(case when t2.out_name = 'lbw' then 1 else 0 end) from wicket_taken as t1 inner join out_type as t2 on t1.kind_out = t2.out_id where t1.innings_no = 2
Question: calculate the average players out in the first innings per match. how many of them were out by the leg before wicket? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extr...
calculate the average players out in the first innings per match. how many of them were out by the leg before wicket?
soccer_2016
select count(match_id) from `match` where match_date like '2008%'
Question: how many matches are there in 2008? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extra_R...
how many matches are there in 2008?
soccer_2016
select count(match_id) from wicket_taken where innings_no = 2
Question: count the matches with a total of two innings. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_...
count the matches with a total of two innings.
soccer_2016
select t1.country_name from country as t1 inner join city as t2 on t1.country_id = t2.country_id where city_name = 'rajkot'
Question: which is the country of the city named 'rajkot'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Typ...
which is the country of the city named 'rajkot'?
soccer_2016
select sum(case when t2.win_type = 'wickets' then 1 else 0 end) from `match` as t1 inner join win_by as t2 on t1.win_type = t2.win_id
Question: how many of the matches are superover? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, Extr...
how many of the matches are superover?
soccer_2016
select t1.team_name from team as t1 inner join match as t2 on t1.team_id = t2.team_1 where t2.win_margin = 38 and match_date = '2009-04-30'
Question: what are the teams that played in a match with the point of winning margin of 38 on april 30, 2009? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. ...
what are the teams that played in a match with the point of winning margin of 38 on april 30, 2009?
soccer_2016
select t1.team_name from team as t1 inner join player_match as t2 on t1.team_id = t2.team_id inner join player as t3 on t2.player_id = t3.player_id where t2.match_id = 335989 and t3.player_name = 't kohli'
Question: give the name of the team of t kohli in the match id 335989. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_I...
give the name of the team of t kohli in the match id 335989.
soccer_2016
select count(t1.venue_name) from venue as t1 inner join city as t2 on t1.city_id = t2.city_id inner join country as t3 on t2.country_id = t3.country_id where t3.country_name = 'south africa' and t2.city_name = 'centurion'
Question: how many venues are located at centurion, south africa? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ex...
how many venues are located at centurion, south africa?
soccer_2016
select count(t1.match_winner) from `match` as t1 inner join team as t2 on t2.team_id = t1.team_1 or t2.team_id = t1.team_2 where t2.team_name = 'delhi daredevils' and t1.match_date like '2014%'
Question: among the matches of delhi daredevils in 2014, how many won matches are there? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_I...
among the matches of delhi daredevils in 2014, how many won matches are there?
soccer_2016
select t2.match_id from team as t1 inner join match as t2 on t1.team_id = t2.match_winner where t1.team_name = 'royal challengers bangalore' and t2.match_date like '2012%' order by t2.win_margin desc limit 1
Question: among the matches played by royal challengers bangalore, what is the match id of the match with the highest winning margin? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -...
among the matches played by royal challengers bangalore, what is the match id of the match with the highest winning margin?
soccer_2016
select count(t1.match_id) from player_match as t1 inner join player as t2 on t1.player_id = t2.player_id inner join rolee as t3 on t1.role_id = t3.role_id where t2.player_name = 'k goel' and t3.role_id = 3
Question: how many times did k goel played as a player only? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_T...
how many times did k goel played as a player only?
soccer_2016
select avg(t1.win_margin) from match as t1 inner join venue as t2 on t1.venue_id = t2.venue_id where t2.venue_name = 'newlands'
Question: what is the average winning margin of the matches held in newlands? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id,...
what is the average winning margin of the matches held in newlands?
soccer_2016
select team_name from team where team_id = ( select case when team_1 = match_winner then team_2 else team_1 end from match where match_id = 336039 )
Question: provide the losing team's name in the match id 336039. | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Ext...
provide the losing team's name in the match id 336039.
soccer_2016
select t1.venue_name from venue as t1 inner join match as t2 on t1.venue_id = t2.venue_id where t2.match_id = 829768
Question: what is the venue for the match id 829768? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, Over_Id, Ball_Id, Extra_Type_Id, ...
what is the venue for the match id 829768?
soccer_2016
select t1.team_name from team as t1 inner join match as t2 on t1.team_id = t2.team_2 order by t2.win_margin limit 1
Question: what is the second team's name in the match with the lowest winning margin? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Runs -> Match_Id, ...
what is the second team's name in the match with the lowest winning margin?
soccer_2016
select cast(sum(case when t2.match_winner = 7 then 1 else 0 end) as real) * 100 / count(t2.match_winner) from team as t1 inner join match as t2 on t1.team_id = t2.match_winner where t2.match_date like '2013%'
Question: among the matches in 2013, what is the percentage of winning of the team 'mumbai indians'? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name. Extra_Type -> Extra_Id, Extra_Name. Extra_Run...
among the matches in 2013, what is the percentage of winning of the team 'mumbai indians'?
soccer_2016
select sum(case when t3.role_id = 1 then 1 else 0 end) - sum(case when t3.role_id > 1 then 1 else 0 end) from player_match as t1 inner join player as t2 on t1.player_id = t2.player_id inner join rolee as t3 on t1.role_id = t3.role_id where t2.player_name = 'sc ganguly'
Question: what is the difference between the number of matches where sc ganguly played as a captain and those matches where he played other roles? | Tables: Batting_Style -> Batting_Id, Batting_hand. Bowling_Style -> Bowling_Id, Bowling_skill. City -> City_Id, City_Name, Country_id. Country -> Country_Id, Country_Name....
what is the difference between the number of matches where sc ganguly played as a captain and those matches where he played other roles?