View Single Post
  #2  
Old March 4th, 2010, 12:15 AM posted to microsoft.public.access.tablesdbdesign
PieterLinden via AccessMonster.com
external usenet poster
 
Posts: 307
Default Player availability list

GeoH wrote:
I am trying to record players availability for team matches throughout a
season. For example I have say a possible total of 50 players and there are
say 40 matches throughout the season. So far about 30 players have advised me
for which of the 40 matches they are available. I wish to record this
availability in Access and then to be able to advise the match manager of the
various games which players are available for the match for which he is
responsible.
I have so far created one table of matches - recording date of fixture,
opposition, venue, match manager and a second table of players. My problem is
how to record which matches the player is available for and then to be able
to extract list of players available for a particular match. Any
help/suggestions would be much appreciated.


Sounds like you're missing a join table...
You have tables for Player and Match, but nothing for Availability.

Availability(
PlayerID,
MatchID,
Available (Yes/No) ... or 1/0 and allow nulls... some people don't like
Yes/No fields.
)

Then if you want to generate a list of all players and all matches, just
create a deliberate cartesian product.

SELECT Players.PlayerID, Matches.MatchID
FROM Players, Matches

then turn it into an append query and append the records to the Availability
table.

--
Message posted via http://www.accessmonster.com