1sf/bird-sql-train-with-schema huggingface dataset:
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: What is the name of the division that has had the lowest number of draft matches in the 2019 season?
Evidence: the lowest number of draft matches refers to MIN(COUNT(FTR = 'D'));
SQL: SELECT T2.name FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2019 AND T1.FTR = 'D' GROUP BY T2.division ORDER BY COUNT(FTR) LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many times did Valencia's home team win in the LaLiga division?
Evidence: LaLiga is a name of the division; Valencia's home team refers to HomeTeam = 'Valencia'; win refers to FTR = 'H';
SQL: SELECT COUNT(T1.HomeTeam) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'LaLiga' AND T1.HomeTeam = 'Valencia' AND T1.FTR = 'H'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: In how many matches in the Seria A division did both teams have equal goals?
Evidence: Seria A is a name of division; equal goals refers to FTR = 'D', where D stands for draft;
SQL: SELECT COUNT(T1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Seria A' AND T1.FTR = 'D'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many football divisions does England have?
Evidence: England is the name of country;
SQL: SELECT COUNT(division) FROM divisions WHERE country = 'England'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: What's the name of the football division in the Netherlands?
Evidence: Netherlands is the name of country;
SQL: SELECT name FROM divisions WHERE country = 'Netherlands'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Who is the winner of the game happened on 2009/10/10, between "East Fife" and "Dumbarton"?
Evidence: 2009/10/10 is a date; the winner refers to FTR = 'A'; East Fife and Dumbarton are name of teams where HomeTeam = 'East Fife'; AwayTeam = 'Dumbarton';
SQL: SELECT CASE WHEN FTR = 'H' THEN 'East Fife' ELSE 'Dumbarton' END WINNER FROM matchs WHERE Date = '2009-10-10' AND HomeTeam = 'East Fife' AND AwayTeam = 'Dumbarton'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: What was the final score for the game Bursaspor vs Denizlispor on 2009/4/26?
Evidence: Bursaspor vs Denizlispor are names of teams where HomeTeam = 'Bursaspor' and AwayTeam = 'Denizlispor'; Date = '2009-04-26'; final score refers to FTHG, FTAG;
SQL: SELECT FTHG, FTAG FROM matchs WHERE Date = '2009-04-26' AND HomeTeam = 'Bursaspor' AND AwayTeam = 'Denizlispor'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: When did the first match that score more than 10 goals happen?
Evidence: score more than 10 goals refers to SUM(FTHG, FTAG)>10, which are short names for Final-time Home-team Goals and Final-time Away-team Goals; the first means the earliest and refers to MIN(Date);
SQL: SELECT MIN(Date) FROM matchs WHERE FTHG + FTAG > 10
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: For the Ligue 2 game that made the most goals, who is the winner of that game?
Evidence: Ligue 2 is the name of division; the most goals refer to MAX(SUM(FTHG, FTAG)) which are short names for Final-time Home-team Goals and Final-time Away-team Goals; winner refers to FTR = 'A';
SQL: SELECT CASE WHEN T1.FTR = 'H' THEN T1.HomeTeam ELSE T1.AwayTeam END WINNER FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Ligue 2' ORDER BY T1.FTAG + T1.FTHG DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many Away Victories happened on 2016/3/27 in the LaLiga 2 division?
Evidence: Away victories refer to FTR = 'A'; LaLiga 2 is the name of division; Date = '2016-03-27';
SQL: SELECT COUNT(T1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'LaLiga 2' AND T1.Date = '2016-03-27' AND T1.FTR = 'A'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many draw games happened on 2018/8/7 for National League?
Evidence: National League is the name of division; Date = '2018-08-07'; draw refers to FTR = 'D'; games refer to Div;
SQL: SELECT COUNT(T1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'National League' AND T1.Date = '2018-08-07' AND T1.FTR = 'D'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which country had the game that Away team made the most goals?
Evidence: the most goals refer to MAX(FTAG), which is a short name for Final-time Away-team Goals;
SQL: SELECT T2.country FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division GROUP BY T2.country ORDER BY SUM(T1.FTAG) DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: For a game had a score of 1-8 in the year of 2011, what division was that game in? Give the full name of the division.
Evidence: 2011 refers to season; a score of 1-8 refers to FTHG = '1' and FTAG = '8';
SQL: SELECT T2.division, T2.name FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2011 AND T1.FTHG = 1 AND T1.FTAG = 8
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which division had the most games with more than 5 total field goals on 2020/2/22? Give the full name of the division?
Evidence: more than 5 total field goals refers to SUM(FTHG, FTAG)>5, which are short names for Final-time Home-team Goals and Final-time Away-team Goals; 2020/2/22 is a date;
SQL: SELECT T2.division, T2.name FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.Date = '2020-02-22' AND T1.FTAG + T1.FTHG > 5 ORDER BY T1.FTAG + T1.FTHG DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Give the full name of the divison that had the most 0-0 games.
Evidence: the most 0-0 games means a no-score draw and refers to MAX(COUNT(Div where FTHG = '0' and FTAG = '0'));
SQL: SELECT T2.name FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.FTAG = 0 AND T1.FTHG = 0 GROUP BY T2.division ORDER BY COUNT(T1.FTAG) DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many Scottish League One games took place on the day that "Pro Vercelli" and "Pescara"had a 5-2 game?
Evidence: Pro Vercelli and Pescara are names of teams; HomeTeam = 'Pro Vercelli'; AwayTeam = 'Pescara'; 5-2 is a score where FTHG = '5' and FTAG = '2'; Scottish League One is a name of division; games refer to Div;
SQL: SELECT COUNT(T1.Date) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Scottish League One' AND T1.Date = ( SELECT Date FROM matchs WHERE FTHG = 5 AND FTAG = 2 AND HomeTeam = 'Pro Vercelli' AND AwayTeam = 'Pescara' )
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: List the number of games that ended up with 5-0 in Greece.
Evidence: 5-0 is a score where FTHG = '5' and FTAG = '0'; Greece is a name of country; games refer to Div;
SQL: SELECT COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.country = 'Greece' AND T1.FTHG = 5 AND T1.FTAG = 0
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which country did Bradford Team belongs to?
Evidence: Bradford team refers to HomeTeam = 'Bradford' or AwayTeam = 'Bradford';
SQL: SELECT DISTINCT T2.country FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.HomeTeam = 'Bradford' OR T1.AwayTeam = 'Bradford'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many Eredivisie teams have played in 2008?
Evidence: Eredivisie is the name of division; 2008 refers to season; teams refer to HomeTeam;
SQL: SELECT COUNT(DISTINCT T1.HomeTeam) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Eredivisie' AND T1.season = 2008
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: What's the home win ratio of the Bundesliga division in 2021?
Evidence: home win refers to FTR = 'H', where H stands for home victory; season = '2021'; Bundesliga is a name of division; DIVIDE(COUNT(Div where FTR = 'H, season = '2021' and name = 'Bundesliga'), COUNT(Div where season = '2021' and name = 'Bundesliga')) as percentage;
SQL: SELECT CAST(COUNT(CASE WHEN T1.FTR = 'H' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T2.name = 'Bundesliga'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: For all the games ended up with 1-1, what percentage of them are from Liga NOS division?
Evidence: 1-1 is a score where FTHG = '1' and FTAG = '1'; Liga NOS is the name of division; DIVIDE(COUNT(Div where FTHG = '1', FTAG = '1', name = 'Liga NOS'), COUNT(Div where FTHG = '1' and FTAG = '1')) as percentage;
SQL: SELECT CAST(COUNT(CASE WHEN T2.name = 'Liga NOS' THEN T1.Div ELSE NULL END) AS REAL) * 100 / COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.FTHG = 1 AND FTAG = 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many matches were held during the 2021 season's Premier League?
Evidence: Premier League is the name of division;
SQL: SELECT COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T2.name = 'Premier League'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which team was the home team in the match of the Bundesliga division on 2020/10/2?
Evidence: Bundesliga is the name of division; Date = '2020/10/2';
SQL: SELECT T1.HomeTeam FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.Date = '2020-10-02' AND T2.name = 'Bundesliga'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which team won the match of the Bundesliga division on 2020/10/2?
Evidence: Bundesliga is the name of division; Date = '2020/10/2'; won the match refers to FTR = 'H';
SQL: SELECT CASE WHEN T1.FTR = 'H' THEN T1.HomeTeam WHEN T1.FTR = 'A' THEN T1.AwayTeam END WINNER FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.Date = '2020-10-02' AND T2.name = 'Bundesliga'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which team has the most victories as the home team in matches of the Bundesliga division?
Evidence: Bundesliga is the name of division; the most victories as the home team refers to MAX(COUNT(FTR = 'H'));
SQL: SELECT T1.HomeTeam FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.FTR = 'H' GROUP BY T1.HomeTeam ORDER BY COUNT(T1.FTR) DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many times did the team Werder Bremen win as the away team in matches of the Bundesliga division?
Evidence: Bundesliga is the name of division; win as the away team refers to FTR = 'A', where 'A' stands for away victory;
SQL: SELECT COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.AwayTeam = 'Werder Bremen' AND T1.FTR = 'A'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many matches of the Bundesliga division ended with an away victory in the 2021 season?
Evidence: Bundesliga is the name of division; away victory refers to FTR = 'A', where 'A' stands for away victory;
SQL: SELECT COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.FTR = 'A' AND T1.season = 2021
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Of the matches in all seasons of the Bundesliga division, how many of them ended with a tie?
Evidence: Bundesliga is the name of division; tie refers to FTR = 'D', where D stands for draft;
SQL: SELECT COUNT(T1.Div) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.FTR = 'D'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many home victories does the Bundesliga division have in more or less than the Premier League division in the 2021 season?
Evidence: Bundesliga and the Premier League are names of division; home victories refer to FTR = 'H', where H stands for home victory; SUBTRACT(COUNT(FTR = 'H' where season = 2021, name = 'Bundesliga'), COUNT(FTR = 'H' where season = 2021, name = 'Premier League'));
SQL: SELECT COUNT(CASE WHEN T2.name = 'Bundesliga' THEN 1 ELSE NULL END) - COUNT(CASE WHEN T2.name = 'Premier League' THEN 1 ELSE NULL END) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T1.FTR = 'H'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Please list the home teams in the matches of the Bundesliga division that ended with a home victory in the 2021 season.
Evidence: Bundesliga is the name of division; home victory refers to refer to FTR = 'H', where H stands for home victory;
SQL: SELECT DISTINCT T1.HomeTeam FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T1.FTR = 'H' AND T2.name = 'Bundesliga'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which team had more home victories in the 2021 season's matches of the Bundesliga division, Augsburg or Mainz?
Evidence: Bundesliga is the name of division; more home victories refer to MAX(FTR = 'H)'; Augsburg and Mainz are names of teams and refer to HomeTeam;
SQL: SELECT CASE WHEN COUNT(CASE WHEN T1.HomeTeam = 'Augsburg' THEN 1 ELSE NULL END) - COUNT(CASE WHEN T1.HomeTeam = ' Mainz' THEN 1 ELSE NULL END) > 0 THEN 'Augsburg' ELSE 'Mainz' END FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T1.FTR = 'H'
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: Which team had the most final-time home-team goals in the 2021 season's matches of the Bundesliga division?
Evidence: Bundesliga is the name of division; the most final-time home-team goals refers to MAX(FTHG);
SQL: SELECT T1.HomeTeam FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.season = 2021 ORDER BY T1.FTHG DESC LIMIT 1
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: How many final-time home-team goals were there in total in all the matches of the Bundesliga division in the 2021 season?
Evidence: Bundesliga is the name of division; final-time home-team goals refers to FTHG;
SQL: SELECT SUM(T1.FTHG) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T2.name = 'Bundesliga' AND T1.season = 2021
Database: european_football_1
Tables: divisions, matchs
Columns (table index, column name): -1, *, 0, division, 0, name, 0, country, 1, Div, 1, Date, 1, HomeTeam, 1, AwayTeam, 1, FTHG, 1, FTAG, 1, FTR, 1, season
Question: What's the winning rate of Club Brugge in the 2021 Premier League?
Evidence: Premier League is name of division; season = 2021; Club Brugge is name of team; Club Brugge wins implies HomeTeam = 'Club Brugge' and FTR = 'H' and AwayTeam = 'Club Brugge' and FTR = 'A'; DIVIDE(SUM(COUNT(FTR = 'H' where HomeTeam = 'Club Brugge', name = 'Premier League', season = 2021), COUNT(FTR = 'A'where AwayTeam = 'Club Brugge', name = 'Premier League', season = 2021)), COUNT(Div where name = 'Premier League', season = 2021));
SQL: SELECT CAST(COUNT(CASE WHEN T1.FTR = 'H' THEN 1 ELSE NULL END) + COUNT(CASE WHEN T1.FTR = 'A' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(t1.FTR) FROM matchs AS T1 INNER JOIN divisions AS T2 ON T1.Div = T2.division WHERE T1.season = 2021 AND T1.AwayTeam = 'Club Brugge' OR T1.HomeTeam = 'Club Brugge'
Database: professional_basketball
Tables: awards_players, coaches, draft, player_allstar, players, teams, awards_coaches, players_teams, series_post
Columns (table index, column name): -1, *, 0, playerID, 0, award, 0, year, 0, lgID, 0, note, 0, pos, 1, coachID, 1, year, 1, tmID, 1, lgID, 1, stint, 1, won, 1, lost, 1, post_wins, 1, post_losses, 2, id, 2, draftYear, 2, draftRound, 2, draftSelection, 2, draftOverall, 2, tmID, 2, firstName, 2, lastName, 2, suffixName, 2, playerID, 2, draftFrom, 2, lgID, 3, playerID, 3, last_name, 3, first_name, 3, season_id, 3, conference, 3, league_id, 3, games_played, 3, minutes, 3, points, 3, o_rebounds, 3, d_rebounds, 3, rebounds, 3, assists, 3, steals, 3, blocks, 3, turnovers, 3, personal_fouls, 3, fg_attempted, 3, fg_made, 3, ft_attempted, 3, ft_made, 3, three_attempted, 3, three_made, 4, playerID, 4, useFirst, 4, firstName, 4, middleName, 4, lastName, 4, nameGiven, 4, fullGivenName, 4, nameSuffix, 4, nameNick, 4, pos, 4, firstseason, 4, lastseason, 4, height, 4, weight, 4, college, 4, collegeOther, 4, birthDate, 4, birthCity, 4, birthState, 4, birthCountry, 4, highSchool, 4, hsCity, 4, hsState, 4, hsCountry, 4, deathDate, 4, race, 5, year, 5, lgID, 5, tmID, 5, franchID, 5, confID, 5, divID, 5, rank, 5, confRank, 5, playoff, 5, name, 5, o_fgm, 5, o_ftm, 5, o_pts, 5, d_pts, 5, homeWon, 5, homeLost, 5, awayWon, 5, awayLost, 5, won, 5, lost, 5, games, 5, arena, 6, id, 6, year, 6, coachID, 6, award, 6, lgID, 6, note, 7, id, 7, playerID, 7, year, 7, stint, 7, tmID, 7, lgID, 7, GP, 7, GS, 7, minutes, 7, points, 7, oRebounds, 7, dRebounds, 7, rebounds, 7, assists, 7, steals, 7, blocks, 7, turnovers, 7, PF, 7, fgAttempted, 7, fgMade, 7, ftAttempted, 7, ftMade, 7, threeAttempted, 7, threeMade, 7, PostGP, 7, PostGS, 7, PostMinutes, 7, PostPoints, 7, PostoRebounds, 7, PostdRebounds, 7, PostRebounds, 7, PostAssists, 7, PostSteals, 7, PostBlocks, 7, PostTurnovers, 7, PostPF, 7, PostfgAttempted, 7, PostfgMade, 7, PostftAttempted, 7, PostftMade, 7, PostthreeAttempted, 7, PostthreeMade, 7, note, 8, id, 8, year, 8, round, 8, series, 8, tmIDWinner, 8, lgIDWinner, 8, tmIDLoser, 8, lgIDLoser, 8, W, 8, L
Question: Among the winning game from the team, what is the percentage of the winning was home game.
Evidence: percentage of winning at the home = Divide(homeWon, won) * 100
SQL: SELECT CAST(homeWon AS REAL) * 100 / won  FROM teams