[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now


Coldfusion/MySQL Calendar insert repeat event based on day of the week.

Posted on 2007-07-23
Medium Priority
Last Modified: 2013-12-16
I have a dynamic calendar that can be edited by my client via a login. They can add repeat events based on the day of the month say the 24th. They can also add repeat events on a daily bases. I would like to know how to go about having them be able to add a repeat event based on the day of the week, like every Wednesday using Coldfusion and MySQL. As of now each event is created as a separate entry.

Any ideas or thoughts would be greatly appreciated.
Question by:kylevn
1 Comment

Accepted Solution

mihaimm earned 1500 total points
ID: 19548769
There are 2 trends of scheduling events. Both have advantages and disadvantages and what you choose strictly depends on your requirements.

1. Define a "master" event that caries the rules for when it is repeated. Then copy that master event into "slaves" that carry each of the occurrences (like for the next 10 years for instance). The advantage is you can modify easily one occurrence and ask the user things like: modify all future occurrences? modify only this one? etc. The obvious disadvantage is storage.

2. Define crontab like records (http://www.adminschoice.com/docs/crontab.htm) and calculate the display on the screen of an occurrence. With crontab scheduling you have very flexible rules (ranging from one time events to repetitive down to the minute). But then updating a single occurrence is difficult as you have to break the original rule into 3 separate ones: before, the occurrence, and after. The obvious advantages are storage and flexibility of scheduling.

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this series, we will discuss common questions received as a database Solutions Engineer at Percona. In this role, we speak with a wide array of MySQL and MongoDB users responsible for both extremely large and complex environments to smaller singl…
In this article, we’ll look at how to deploy ProxySQL.
The purpose of this video is to demonstrate how to set up an RSS Feed on a WordPress Website. This will be demonstrated using a Windows 8 PC. Feedburner will be used for this demonstration. Go to your WordPress login page. This will look like the…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.
Suggested Courses

873 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question