I have got the following tables set up in MS Access(will be using MYSQL hence strange format when I can get my hands on it.)
stop_id int unsigned auto_increment primary key,
stop_name char(32) name of stop
bus_id int unsigned auto_increment primary key,
bus_name, char(16) name of bus (possible int works here as well)
bus_id int unsigned,
stop_id int unsigned,
unique scheduled_stop (bus_id,stop_id,stop_time)
I have been trying to design a query that gives the following...
"Give me a list of buses that run from x lane to y lane on or after y time."
Anybody got any ideas? Obviously a bus, say the 51 runs many times each day and it may include stop x but not stop y. Whereas another service eg 11 might have both x and y and this would be the required answer.
Thank-you, it's much appreciated.