How many units of item no.5 were sold in store no.3 on the day the temperature range was the biggest?
item no. 5 refers to item_nbr = 5; store no.3 refers to store_nbr = 3; when the temperature range was the biggest refers to Max(Subtract(tmax, tmin))
SELECT t2.units FROM relation AS T1 INNER JOIN sales_in_weather AS T2 ON T1.store_nbr = T2.store_nbr INNER JOIN weather AS T3 ON T1.station_nbr = T3.station_nbr WHERE T2.store_nbr = 3 AND T2.item_nbr = 5 ORDER BY t3.tmax - t3.tmin DESC LIMIT 1
database name:db_id sales_in_weather
sales_in_weather table sales_in_weather Cols: date dtype date, store number dtype integer, item number dtype integer, units dtype integer, 
weather table weather Cols: station number dtype integer, date dtype date, temperature max dtype integer, temperature min dtype integer, temperature average dtype integer, departure from normal dtype integer, dew point dtype integer, wet bulb dtype integer, heat dtype integer, cool dtype integer, sunrise dtype text, sunset dtype text, code summarization dtype text, snowfall dtype real, preciptotal dtype real, station pressure dtype real, sea level dtype real, resultant speed dtype real, resultant direction dtype integer, average speed dtype real, 
relation table relation Cols: store number dtype integer, station number dtype integer, 
