Deleting old events from Calendar ?

Get help from the community here.

Moderator: Developers

jhsdurham
Posts: 73
Joined: Sun Sep 15, 2013 4:04 am

Deleting old events from Calendar ?

Postby jhsdurham » Fri Nov 08, 2019 12:48 am

Hello,

When we first stared using GO in 2012, it was almost exclusively for the calendar function.

We have never deleted old stuff from the calendar.

Would I be right in thinking that if we wanted to trim out old data, I can do so safely by deleting records from the table cal_events ? If I delete them from there, will that break connections to something else? I was planning to do it like this to keep just the last 2 years of calendar data.

DELETE FROM cal_events WHERE ctime < UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 730 DAY)) ;

If this is a bad idea, what is the recommended way to remove old calendar rows?
mschering
Site Admin
Site Admin
Posts: 8329
Joined: Tue Apr 20, 2004 1:06 pm
Location: The Netherlands - Den Bosch
Contact:

Re: Deleting old events from Calendar ?

Postby mschering » Mon Nov 18, 2019 10:18 am

You can use the command line for it:

php groupofficecli.php calendar/event/deleteOld --data=2016-01-01
Best regards,

Merijn Schering
Intermesh

Who is online

Users browsing this forum: No registered users and 2 guests