I am currently in the process of setting up a database for a swimming club.
One table in the database will hold the Personal Best times of each swimmer over different distances -
PB(SwimmerID, Distance, Time)
These personal best times will be entered for each swimmer whenever the database is setup.
The database will also be used to store the results from the competitions which the swimmers compete in. Two tables will be used for this -
Event(Event ID, Event Name, Distance, Date)
Results(Event ID, SwimmerID, Position, Time)
These two tables are linked by Event ID.
Now for the problem that I have –
I want the database to automatically update the personal best table if the swimmer swims a faster time in one of the races – the results of which are entered into the database. E.g If someones personal best for 100m freestyle is 52 seconds and they then swim 51 seconds I want the database to use an update query to update the PB table.
I have tried to write an update query to solve this but I have not had any success. If you could help me with this I would be most grateful.
Thanks
One table in the database will hold the Personal Best times of each swimmer over different distances -
PB(SwimmerID, Distance, Time)
These personal best times will be entered for each swimmer whenever the database is setup.
The database will also be used to store the results from the competitions which the swimmers compete in. Two tables will be used for this -
Event(Event ID, Event Name, Distance, Date)
Results(Event ID, SwimmerID, Position, Time)
These two tables are linked by Event ID.
Now for the problem that I have –
I want the database to automatically update the personal best table if the swimmer swims a faster time in one of the races – the results of which are entered into the database. E.g If someones personal best for 100m freestyle is 52 seconds and they then swim 51 seconds I want the database to use an update query to update the PB table.
I have tried to write an update query to solve this but I have not had any success. If you could help me with this I would be most grateful.
Thanks