One option insert the record into the database once and allow the user
to select(if needed) an interval for which the event is to repeat. If
they pick one week use a database column titled "interval" or something
similar. You will also need a "repeating" boolean value to tell if the
event repeats perpetually. You can then use DateAdd() to generate the
other entries and add them to your own hand-built query.

The other, as stated before, is to use DateAdd() from the start date and
the number of days specified in an "interval" variable to increment the
date and add records. I would recommend the addition of a cut off date
to stop adding schedule records.

It really depends on which matters more to you: coding simplicity and
lighter database server load vs. greater data storage needs. 

> -----Original Message-----
> > From: Rick Faircloth [mailto:[EMAIL PROTECTED]]
> > Sent: 14 January 2003 14:07
> > To: CF-Talk
> > Subject: How to handle Calendar Scheduling of Recurring Events?
> >
> >
> > Hi, all.
> >
> > I was wondering about the various approaches that have been taken to
> > scheduling
> > recurring events in a calendar?
> >
> > I haven't worked with auto-insertion of recurring events, but now is
> > the time for my calendar creation to become more sophisticated.
> >
> > Should I insert data for "one-time" events in one table and data
> > for "recurring" events in another with the user specifiying daily,
> > weekly, monthly, quarterly, yearly, etc...and have code that
> > checks that table and auto-inserts those events when the day/dates
> > are checked?
> >
> > How would I handle the City Council meeting that is scheduled on
> > "the 2nd Tuesday of each month."  Would I have the person inputting
> > the data fill out or check fields for "1st, 2nd, 3rd, etc.", then
> > "Tuesday,
> > Wednesday, etc.",
> > each "Week, Month, Year" or whatever?  (That could get really
> > complicated...)
> > Just let them handle that kind of insertion manually?


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Signup for the Fusion Authority news alert and keep up with the latest news in 
ColdFusion and related topics. http://www.fusionauthority.com/signup.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to