phppup Posted November 13, 2022 Share Posted November 13, 2022 As a rudimentary example, I want to allow users to set an appointment. I'm considering a drop-down that will display 1,2,3, and 4 o'clock. There are 2 appointment slots available each hour. After the 2nd appointment is filled for a specific time, the option will be removed from the drop-down selection. I've essentially gotten the necessary mechanics figured out and plan to eliminate a timeslot when a SELECT returns 2 as the number of current appointments for a specified time. My question is: How can I ensure that additional appointments are not set from the time that the first appointment refreshes the drop-down to the time the option is removed. I realize this is a thin possibility, but theoretically, 10 users could have the opportunity to grab the second slot. If they all hit enter simultaneously, how can I prevent an overloaded schedule (since the time itself is not unique)? Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.