QIAN-ME/bird_schema_data huggingface dataset:
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    Which weather station does the store that sold the highest quantity of item 9 belongs to? item 9 refers to item_nbr = 9; sold the highest quantity refers to Max(Sum(units)); weather station refers to station_nbr

    【Evidence】
    item 9 refers to item_nbr = 9; sold the highest quantity refers to Max(Sum(units)); weather station refers to station_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT station_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T1.item_nbr = 9 GROUP BY T2.station_nbr ORDER BY SUM(T1.units) DESC LIMIT 1
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    How many stores belong to the most windy station? most windy station refers to Max(avgspeed)

    【Evidence】
    most windy station refers to Max(avgspeed)

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT COUNT(store_nbr) FROM relation WHERE station_nbr = ( SELECT station_nbr FROM weather ORDER BY avgspeed DESC LIMIT 1 )
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    Among the stores in weather station 14 in February 2014, which store had sold no less than 300 quantities for item number 44 in a single day? weather station 14 refers to station_nbr = 14; February 2014 refers to substring (date, 1, 7) = '2014-02' ; sold no less than 300 quantities refers to units > = 300; item no.44 refers to item_nbr = 44; store refers to store_nbr

    【Evidence】
    weather station 14 refers to station_nbr = 14; February 2014 refers to substring (date, 1, 7) = '2014-02' ; sold no less than 300 quantities refers to units > = 300; item no.44 refers to item_nbr = 44; store refers to store_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T1.store_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T2.station_nbr = 14 AND T1.`date` LIKE '%2014-02%' AND T1.item_nbr = 44 AND units >= 300
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    What is the most purchased products during the rainy days in June 2013 in weather station 9? most purchased product refers to Max(units); during the rainy day refers to codesum = RA; in June 2013 refers to SUBSTR(date, 1, 7) = '2013-06'; weather station 9 refers to station_nbr = 9; product refers to item_nbr

    【Evidence】
    most purchased product refers to Max(units); during the rainy day refers to codesum = RA; in June 2013 refers to SUBSTR(date, 1, 7) = '2013-06'; weather station 9 refers to station_nbr = 9; product refers to item_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T1.item_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr INNER JOIN weather AS T3 ON T2.station_nbr = T3.station_nbr WHERE T3.station_nbr = 9 AND T1.`date` LIKE '%2013-06%' AND codesum = 'RA' ORDER BY T1.units DESC LIMIT 1
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    Which station sold the highest quantity of item number 5 overall? item number 5 refers to item_nbr = 5; sold highest quantity refers to Max(Sum(units)); station refers to station_nbr

    【Evidence】
    item number 5 refers to item_nbr = 5; sold highest quantity refers to Max(Sum(units)); station refers to station_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T2.station_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T1.item_nbr = 5 GROUP BY T2.station_nbr ORDER BY SUM(T1.units) DESC LIMIT 1
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    What is the earliest sunrise recorded in the stations with no more than 1 store in February 2012? in February 2012 refers to SUBSTR(date, 1, 7) = '2012-02'; earliest sunrise Min(sunrise);  station with no more than 1 store refers to station_nbr where Count(store_nbr) = 1

    【Evidence】
    in February 2012 refers to SUBSTR(date, 1, 7) = '2012-02'; earliest sunrise Min(sunrise);  station with no more than 1 store refers to station_nbr where Count(store_nbr) = 1

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T1.station_nbr FROM relation AS T1 INNER JOIN weather AS T2 ON T1.station_nbr = T2.station_nbr WHERE sunrise IS NOT NULL AND T2.`date` LIKE '%2012-02%' AND T1.station_nbr IN ( SELECT station_nbr FROM relation GROUP BY station_nbr HAVING COUNT(store_nbr) = 1 ) ORDER BY sunrise LIMIT 1
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    In weather station 17, which store sold the highest quantity of item 45 in October 2012? weather station 17 refers to station_nbr = 17; item 45 refers to item_nbr = 45; in October 2012 refers to SUBSTR(date, 1, 7) = '2012-10': highest quantity refers to Max(Sum(units)); store refers to store_nbr

    【Evidence】
    weather station 17 refers to station_nbr = 17; item 45 refers to item_nbr = 45; in October 2012 refers to SUBSTR(date, 1, 7) = '2012-10': highest quantity refers to Max(Sum(units)); store refers to store_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T1.store_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr WHERE T1.item_nbr = 45 AND T2.station_nbr = 17 AND T1.`date` LIKE '%2012-10%' GROUP BY T1.store_nbr ORDER BY SUM(T1.units) DESC LIMIT 1
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    What are the items sold by the store during the day whose station recorded the thickest snowfall? thickest snowfall refers to Max(snowfall); item refers to item_nbr

    【Evidence】
    thickest snowfall refers to Max(snowfall); item refers to item_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T1.item_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr INNER JOIN ( SELECT station_nbr, `date` FROM weather ORDER BY snowfall DESC LIMIT 1 ) AS T3 ON T2.station_nbr = T3.station_nbr
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    What are the top 3 stations that have sold the highest quantities for an item in a single day? highest quantity refers to Max(units); station refers to station_nbr

    【Evidence】
    highest quantity refers to Max(units); station refers to station_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT T2.station_nbr FROM sales_in_weather AS T1 INNER JOIN relation AS T2 ON T1.store_nbr = T2.store_nbr ORDER BY T1.units DESC LIMIT 3
You are now a sqlite data analyst, and you are given a database schema as follows:

    【Schema】
    【DB_ID】 sales_in_weather
【Schema】
# Table: sales_in_weather
[
(date:DATE, Primary Key, Examples: [2012-01-01]),
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(item_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(units:INTEGER, Examples: [0, 29, 2])
]
# Table: relation
[
(store_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(station_nbr:INTEGER, Examples: [1, 14, 7])
]
# Table: weather
[
(station_nbr:INTEGER, Primary Key, Examples: [1, 2, 3]),
(date:DATE, Primary Key, Examples: [2012-01-01]),
(tmax:INTEGER, Examples: [52, 50, 32]),
(tmin:INTEGER, Examples: [31, 11, 9]),
(tavg:INTEGER, Examples: [42, 41, 22]),
(depart:INTEGER, Examples: [16, 12, -6]),
(dewpoint:INTEGER, Examples: [36, 26, 4]),
(wetbulb:INTEGER, Examples: [40, 35, 18]),
(heat:INTEGER, Examples: [23, 24, 43]),
(cool:INTEGER, Examples: [0, 5, 6]),
(sunrise:TEXT, Examples: [07:16:00, 07:15:00, 07:14:00]),
(sunset:TEXT, Examples: [16:26:00, 16:27:00, 16:28:00]),
(codesum:TEXT, Examples: [RA FZFG BR,  , SN]),
(snowfall:REAL, Examples: [0.0, 0.05, 0.2]),
(preciptotal:REAL, Examples: [0.05, 0.01, 0.0]),
(stnpressure:REAL, Examples: [29.78, 29.44, 29.67]),
(sealevel:REAL, Examples: [29.92, 29.62, 29.87]),
(resultspeed:REAL, Examples: [3.6, 9.8, 10.8]),
(resultdir:INTEGER, Examples: [20, 24, 31]),
(avgspeed:REAL, Examples: [4.6, 10.3, 11.6])
]
【Foreign keys】
relation.store_nbr=sales_in_weather.store_nbr
relation.station_nbr=weather.station_nbr

    【Question】
    How many stores belong to the station with the highest recorded heat of all time? highest recorded heat refers to Max(heat); station refers to station_nbr

    【Evidence】
    highest recorded heat refers to Max(heat); station refers to station_nbr

    Please read and understand the database schema carefully, and generate an executable SQL based on the user's question and evidence. 

SQL: SELECT COUNT(T2.store_nbr) FROM ( SELECT station_nbr FROM weather ORDER BY heat DESC LIMIT 1 ) AS T1 INNER JOIN relation AS T2 ON T1.station_nbr = T2.station_nbr