Dludora/DAIL-BIRD huggingface dataset:
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who has the heaviest weight? who refers to PlayerName; heaviest weight refers to MAX(weight_in_kg); */
SELECT 
SELECT T1.PlayerName FROM PlayerInfo AS T1 INNER JOIN weight_info AS T2 ON T1.weight = T2.weight_id ORDER BY T2.weight_in_kg DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: What is the percentage of players who were born in Denmark and weight above 154 lbs? percentage = MULTIPLY(DIVIDE(SUM(weight_in_lbs > 154 and nation = 'Denmark'), COUNT(ELITEID)), 100); players refers to PlayerName; born in Denmark refers to nation = 'Denmark'; weight above 154 lbs refers to weight_in_lbs > 154; */
SELECT 
SELECT CAST(COUNT(CASE WHEN T1.nation = 'Denmark' AND T2.weight_in_lbs > 154 THEN T1.ELITEID ELSE NULL END) AS REAL) * 100 / COUNT(T1.ELITEID) FROM PlayerInfo AS T1 INNER JOIN weight_info AS T2 ON T1.weight = T2.weight_id
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Which team does Andreas Jamtin belong to? FALSE; */
SELECT 
SELECT DISTINCT T1.TEAM FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.PlayerName = 'Andreas Jamtin'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List out the seasons that Niklas Eckerblom played. FALSE; */
SELECT 
SELECT DISTINCT T1.SEASON FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.PlayerName = 'Niklas Eckerblom'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Mention the type of game that Matthias Trattnig played. type of game refers to GAMETYPE; */
SELECT 
SELECT DISTINCT T1.GAMETYPE FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.PlayerName = 'Matthias Trattnig'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List out the nation of players who played for the 1997-1998 season . players refers to PlayerName; 1997-1998 season refers to SEASON = '1997-1998'; */
SELECT 
SELECT DISTINCT T2.nation FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '1997-1998'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: What is the highest point highest point of Per Mars in the draft year? highest point in the draft year refers to MAX(P); */
SELECT 
SELECT T1.P FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.PlayerName = 'Per Mars' ORDER BY T1.P DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Among the Italian players, who has the shortest height? Italian refers to nation = 'Italy'; players refers to PlayerName; shortest height refers to MIN(height_in_cm); */
SELECT 
SELECT T2.PlayerName FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height WHERE T2.nation = 'Italy' ORDER BY T1.height_in_cm ASC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List out the name of players who have a height of 5'8". name of players refers to PlayerName; height of 5'8" refers to height_in_inch = '5''8"'; */
SELECT 
SELECT T2.PlayerName FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height WHERE T1.height_in_inch = '5''8"'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: How many players were born in 1982 and have a height above 182cm? born in 1982 refers to birthyear = 1982; height above 182cm refers to height_in_cm > 182 ; */
SELECT 
SELECT COUNT(T2.ELITEID) FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height WHERE T1.height_in_cm > 182 AND strftime('%Y', T2.birthdate) = '1982'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: What is the percentage of Russian players who have a height of under 200 inch? percentage = MULTIPLY(DIVIDE(SUM(nation = 'Russia' WHERE height_in_cm < 200), COUNT(ELITEID)), 100); Russian refers to nation = 'Russia'; players refers to PlayerName; height of under 200 inch refers to height_in_cm < 200; */
SELECT 
SELECT CAST(COUNT(CASE WHEN T1.height_in_cm < 200 AND T2.nation = 'Russia' THEN T2.ELITEID ELSE NULL END) AS REAL) * 100 / COUNT(T2.ELITEID) FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Among the USA players, who has the lightest weight? USA refers to nation = 'USA' ; players refers to PlayerName; lightest weight refers to MIN(weight_in_lbs); */
SELECT 
SELECT T2.PlayerName FROM weight_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.weight_id = T2.weight WHERE T2.nation = 'USA' ORDER BY T1.weight_in_lbs ASC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who among the players in season 2000-2001 has committed the highest rule violations or penalty minutes? committed the highest rule violations or penalty minutes refers to MAX(PIM); 2000-2001 season refers to SEASON = '2000-2001' */
SELECT 
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' ORDER BY T1.PIM DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List the names of all players in team Avangard Omsk in season 2000-2001. names of the players refers to PlayerName; team Avangard Omsk refers to TEAM = 'Avangard Omsk'; 2000-2001 season refers to SEASON = '2000-2001'; */
SELECT 
SELECT DISTINCT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.TEAM = 'Avangard Omsk'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who among the players drafted by Arizona Coyotes in 2000 has committed the highest rule violations? who refers to PlayerName; drafted by Arizona Coyotes refers to overallby = 'Arizona Coyotes'; committed the highest rule violations refers to MAX(PIM); in 2000 refers to draftyear = 2000; */
SELECT 
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T2.overallby = 'Arizona Coyotes' AND T2.draftyear = 2000 ORDER BY T1.PIM DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: How many players were drafted by Arizona Coyotes whose height reaches 195 centimeters? drafted by Arizona Coyotes refers to overallby = 'Arizona Coyotes'; height reaches 195 centimeters refers to height_in_cm = 195; */
SELECT 
SELECT COUNT(T2.ELITEID) FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height WHERE T2.overallby = 'Arizona Coyotes' AND T1.height_in_cm = 195
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List the names of all players from Avangard Omsk that have played for playoffs in season 2000-2001. names of the players refers to PlayerName; Avangard Omsk refers to TEAM = 'Avangard Omsk'; playoffs refers to GAMETYPE = 'Playoffs'; 2000-2001 season refers to SEASON = '2000-2001'; */
SELECT 
SELECT DISTINCT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.TEAM = 'Avangard Omsk' AND T1.GAMETYPE = 'Playoffs'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who is the most valuable player who played in the 2000-2001 season of the International league? most valuable player refers to MAX(P); 2000-2001 season refers to SEASON = '2000-2001'; International league refers to LEAGUE = 'International'; */
SELECT 
SELECT DISTINCT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.LEAGUE = 'International' ORDER BY T1.P DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: How many players who were born in 1980 weigh 185 in pounds? born in 1980 refers to birthyear = 1980; weigh 185 in pounds refers to weight_in_lbs = 185; */
SELECT 
SELECT COUNT(T2.ELITEID) FROM weight_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.weight_id = T2.weight WHERE T1.weight_in_lbs = 185 AND strftime('%Y', T2.birthdate) = '1980'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who has played the most game plays in the 2000-2001 season of the International league? played the most game plays refers to MAX(GP); 2000-2001 season refers to SEASON = '2000-2001'; International league refers to LEAGUE = 'International'; */
SELECT 
SELECT DISTINCT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.LEAGUE = 'International' ORDER BY T1.GP DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: List the names of all players from Avangard Omsk who played in the 2000-2001 season of the International league that have no goals in draft year. names of the players refers to PlayerName; Avangard Omsk refers to TEAM = 'Avangard Omsk'; International league refers to LEAGUE = 'International'; no goals in draft year refers to G = 0; 2000-2001 season refers to SEASON = '2000-2001'; */
SELECT 
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.LEAGUE = 'International' AND T1.TEAM = 'Czech Republic (all)' AND T1.G = 0
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Who is the oldest player who played for Avangard Omsk during the regular season in 2000-2001? oldest player refers to MIN(birthdate); Avangard Omsk refers to TEAM = 'Avangard Omsk'; regular season refers to GAMETYPE = 'Regular Season'; 2000-2001 season refers to SEASON = '2000-2001'; */
SELECT 
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2000-2001' AND T1.GAMETYPE = 'Regular Season' AND T1.TEAM = 'Avangard Omsk' ORDER BY T2.birthdate ASC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Among the players who played in OHL league during the regular season in 2007-2008, who is the player that attained the most number of assist? OHL league refers to LEAGUE = 'OHL'; who refers to PlayerName; regular season refers to GAMETYPE = 'Regular Season'; most number of assist refers to MAX(A); 2007-2008 season refers to SEASON = '2007-2008'; */
SELECT 
SELECT T2.PlayerName FROM SeasonStatus AS T1 INNER JOIN PlayerInfo AS T2 ON T1.ELITEID = T2.ELITEID WHERE T1.SEASON = '2007-2008' AND T1.LEAGUE = 'OHL' AND T1.GAMETYPE = 'Regular Season' ORDER BY T1.A DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: How many teams did the heaviest player drafted by Arizona Coyotes have played for? heaviest player refers to MAX(weight_in_lb); drafted by Arizona Coyotes refers to overallby = 'Arizona Coyotes'; */
SELECT 
SELECT COUNT(T2.TEAM) FROM PlayerInfo AS T1 INNER JOIN SeasonStatus AS T2 ON T1.ELITEID = T2.ELITEID INNER JOIN weight_info AS T3 ON T1.weight = T3.weight_id WHERE T1.overallby = 'Arizona Coyotes' ORDER BY T3.weight_in_lbs DESC LIMIT 1
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Calculate the average weight in pounds of all players drafted by Arizona Coyotes. average weight in pounds = AVG(weight_in_lbs); weight in pounds refers to weight_in_lbs; players refers to PlayerName; drafted by Arizona Coyotes refers to overallby = 'Arizona Coyotes'; */
SELECT 
SELECT CAST(SUM(T1.weight_in_lbs) AS REAL) / COUNT(T2.ELITEID) FROM weight_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.weight_id = T2.weight WHERE T2.overallby = 'Arizona Coyotes'
/* Given the following database schema: */
CREATE TABLE height_info
(
    height_id      INTEGER
            primary key,
    height_in_cm   INTEGER,
    height_in_inch TEXT
)

CREATE TABLE weight_info
(
    weight_id     INTEGER
            primary key,
    weight_in_kg  INTEGER,
    weight_in_lbs INTEGER
)

CREATE TABLE PlayerInfo
(
    ELITEID           INTEGER
            primary key,
    PlayerName        TEXT,
    birthdate         TEXT,
    birthyear         DATE,
    birthmonth        INTEGER,
    birthday          INTEGER,
    birthplace        TEXT,
    nation            TEXT,
    height            INTEGER,
    weight            INTEGER,
    position_info     TEXT,
    shoots            TEXT,
    draftyear         INTEGER,
    draftround        INTEGER,
    overall           INTEGER,
    overallby         TEXT,
    CSS_rank          INTEGER,
    sum_7yr_GP        INTEGER,
    sum_7yr_TOI       INTEGER,
    GP_greater_than_0 TEXT,
    foreign key (height) references height_info(height_id),
    foreign key (weight) references weight_info(weight_id)
)

CREATE TABLE SeasonStatus
(
    ELITEID   INTEGER,
    SEASON    TEXT,
    TEAM      TEXT,
    LEAGUE    TEXT,
    GAMETYPE  TEXT,
    GP        INTEGER,
    G         INTEGER,
    A         INTEGER,
    P         INTEGER,
    PIM       INTEGER,
    PLUSMINUS INTEGER,
    foreign key (ELITEID) references PlayerInfo(ELITEID)
)

/* Answer the following: Calculate the average height in centimeter of all players who played in Acadie-Bathurst Titan during regular season. average height in centimeter = AVG(height_in_cm); height in centimeter refers to height_in_cm; players refers to PlayerName; Acadie-Bathurst Titan refers to TEAM = 'Acadie-Bathurst Titan'; regular season refers to GAMETYPE = 'Regular Season'; */
SELECT 
SELECT CAST(SUM(T1.height_in_cm) AS REAL) / COUNT(T2.ELITEID) FROM height_info AS T1 INNER JOIN PlayerInfo AS T2 ON T1.height_id = T2.height INNER JOIN SeasonStatus AS T3 ON T2.ELITEID = T3.ELITEID WHERE T3.TEAM = 'Acadie-Bathurst Titan' AND T3.GAMETYPE = 'Regular Season'