Hello all,
I'm looking to develop a small script where users can insert their "schedule." However, I need some help determining the logic of how to create the DB structure and how to input the "time" of the events in the database.
One thing to note, however, is that when users enter their "schedule", they will not be entering exact dates. Instead, they will be entering 'days of the week.' Somewhat like a 'recurring' appointment.
For example, User A could enter the following time schedule:
MWF - 8:00am - 10:00am MW - 2:00pm - 3:00pm etc...
As you can see, I'm looking for a way to use generic 'days of the week', not necessarily exact dates.
With this in mind, what would be the best way to store this in the database, knowing that eventually, I may be "querying" the database to search for available times.
Should I enter them in milliseconds or seconds? With "0" being 12:00AM on Sunday?
Any suggestions would be great.
Thanks!