Tagged: edit dates
June 28, 2020 at 6:08 AM #30138Richard WendrockParticipant
With the pandemic, we are forced to reschedule events. Postponing them with the hopes that restrictions will be lifted. Please provide the option to edit the start and end dates. I realize there are many records in the database that must be changed. But those records can be change with SQL statements like this
The table names in your database will have a different prefix but the name following holy_ will be the same. In this case our event was schedule for June 25-28, 2020.
SET first_date = ‘2020-08-06’, last_date= ‘2020-08-09’
WHERE last_date = ‘2020-06-28’ ;
SET first_date = ‘2020-08-06’, last_date= ‘2020-08-06’
WHERE first_date = ‘2020-06-25’ ;
SET dates = ‘2020-08-06’
WHERE dates = ‘2020-06-25’ ;
SET dates = ‘2020-08-07’
WHERE dates = ‘2020-06-26’ ;
SET dates = ‘2020-08-08’
WHERE dates = ‘2020-06-27’ ;
SET dates = ‘2020-08-09’
WHERE dates = ‘2020-06-28’ ;
SET date = ‘2020-08-06’
WHERE date = ‘2020-06-25’ ;
SET date = ‘2020-08-07’
WHERE date = ‘2020-06-26’ ;
SET date = ‘2020-08-08’
WHERE date = ‘2020-06-27’ ;
SET date = ‘2020-08-09’
WHERE date = ‘2020-06-28’ ;
June 28, 2020 at 9:17 AM #30148Stephen SherrardKeymaster
Believe me, I have thought about this many times, and am actually working through some of this now on a new (as yet unannounced) replacement for the free plugin… rebuilding it from scratch with a much better database structure, and true classes for each object (events, tasks, fields, signups, etc.) with proper methods. One big reason is to also allow true repeating events, using an rRule type system used by iCal and Google and others, and integrating the much better Full Calendar ( https://fullcalendar.io/ ). It will also allow custom fields, signup templates, and much more all built into what will most likely be the new free base plugin.
Those SQL queries would certainly work, but that’s a brute force method that simply changes every date it finds in every table to a new date, without regards for which sheet or task it’s coming from (and you still need to provide an admin interface to specify which dates to change, and the date to change it to, and what to do with Multi-Day and Recurring events). There is a LOT more to consider and code (I’m going through it all now, and it’s very complex, especially for events that are Repeating or Multi-Day).
What happens if you only want to reschedule a specific event?
What happens if you only want to reschedule one day of a repeating/recurring event? Or you need to reschedule all of the days of a repeating/recurring or Multi-Day event?
Do we move the signups as well and just assume that everyone who signed up for the first date can also make it to the new date? Or do we delete those signups and have people signup again?
Do we send out email notices to everyone who signed up letting them know the dates have changed? Do we reset their email reminders (reminder 1 and reminder 2) so that they will get sent again?
The list goes on, and most of these things would need to be options for the admin to choose how to handle each case.
For now, you’ve already figured out the best way if you want to brute force change every date in the database to another date, just do it in your server’s database admin program.
- You must be logged in to reply to this topic.