-- Database schema
| station : id [ INTEGER ] primary_key , name [ TEXT ] , lat [ REAL ] , long [ REAL ] , dock_count [ INTEGER ] , city [ TEXT ] , installation_date [ TEXT ] | status : station_id [ INTEGER ] , bikes_available [ INTEGER ] , docks_available [ INTEGER ] , time [ TEXT ] | trip : id [ INTEGER ] primary_key , duration [ INTEGER ] , start_date [ TEXT ] , start_station_name [ TEXT ] , start_station_id [ INTEGER ] , end_date [ TEXT ] , end_station_name [ TEXT ] , end_station_id [ INTEGER ] , bike_id [ INTEGER ] , subscription_type [ TEXT ] , zip_code [ INTEGER ] | weather : date [ TEXT ] , max_temperature_f [ INTEGER ] , mean_temperature_f [ INTEGER ] , min_temperature_f [ INTEGER ] , max_dew_point_f [ INTEGER ] , mean_dew_point_f [ INTEGER ] , min_dew_point_f [ INTEGER ] , max_humidity [ INTEGER ] , mean_humidity [ INTEGER ] , min_humidity [ INTEGER ] , max_sea_level_pressure_inches [ REAL ] , mean_sea_level_pressure_inches [ REAL ] , min_sea_level_pressure_inches [ REAL ] , max_visibility_miles [ INTEGER ] , mean_visibility_miles [ INTEGER ] , min_visibility_miles [ INTEGER ] , max_wind_Speed_mph [ INTEGER ] , mean_wind_speed_mph [ INTEGER ] , max_gust_speed_mph [ INTEGER ] , precipitation_inches [ TEXT ] , cloud_cover [ INTEGER ] , events [ TEXT ] , wind_dir_degrees [ INTEGER ] , zip_code [ TEXT ] |
-- -- Find the average ride time of the bikes that started at Steuart at Market station and ended at Embarcadero at Sansome station in July 2014.

SELECT AVG(duration) FROM trip WHERE start_date = '7/1/2014%' AND end_date = '7/31/2014%' AND start_station_name = 'Steuart at Market' AND end_station_name = 'Embarcadero at Sansome';