Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I would like to limit the number of entries in a column 1

Status
Not open for further replies.

midnightrambler75

Technical User
Nov 7, 2004
8
0
0
CA
I am a bit of novice and need some suggestions/help.

My database is being used for an event. I have a table containing the mailing list. These people then RSVP for the event and let us know how many people will be attending. Here is the problem.

I want to record the number of people attending but limit it to a certain number.

Any recommendations? Should I set up a new table to record RSVP's or can I add a column in the mailing list?

Thanks
Midnightrambler75
 
I would have a field in the Events table 'MaxAttendees', a new table for RSVPs that includes the EventID, the PersonID who's attending and a field for number of participants (if applicable - for instance, I might bring my whole family and that would be 4 people attending - this may not be necessary for your application though). Then when you want to add someone to an event, add up the number of people attending for that event and if it is less than the 'MaxAttendees' for that event, add that person to the RSVP table.

HTH

Leslie
 
Thanks, that makes sence. How do I lock the field onces total 'Attendees' equals 'MaxAttendees'? I assume its an event procedure.

Thanks
MR75
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top