3
|
1 -- add identifier for recurring instances and exceptions
|
|
2
|
|
3 ALTER TABLE `events` ADD `instance` varchar(16) NOT NULL DEFAULT '' AFTER `uid`;
|
|
4 ALTER TABLE `events` ADD `isexception` tinyint(1) NOT NULL DEFAULT '0' AFTER `instance`;
|
|
5
|
|
6 UPDATE `events` SET `instance` = DATE_FORMAT(`start`, '%Y%m%d')
|
|
7 WHERE `recurrence_id` != 0 AND `instance` = '' AND `all_day` = 1;
|
|
8
|
|
9 UPDATE `events` SET `instance` = DATE_FORMAT(`start`, '%Y%m%dT%k%i%s')
|
|
10 WHERE `recurrence_id` != 0 AND `instance` = '' AND `all_day` = 0;
|
|
11
|
|
12 -- extend alarms columns for multiple values
|
|
13
|
|
14 ALTER TABLE `events` CHANGE `alarms` `alarms` TEXT NULL DEFAULT NULL;
|
|
15
|