ALTER TABLE `general_system_settings` DROP `finalSeminarMaxActiveParticipants`;

-- Dont forget to set these to 2 and 5
ALTER TABLE `general_system_settings` ADD `finalSeminarMinOpponents` int(11) NOT NULL;
ALTER TABLE `general_system_settings` ADD `finalSeminarMinParticipants` int(11) NOT NULL;

-- Dont forget to make future seminars in production db have 2 and 5 as maximum instead of 0 which will be the default after this query has been run
ALTER TABLE `final_seminar` ADD `maxOpponents` int(11) NOT NULL;
ALTER TABLE `final_seminar` ADD `maxParticipants` int(11) NOT NULL;

ALTER TABLE `Exemption`
ADD `expirationDate` datetime NOT NULL;

-- Double check production database if any new exemptions without expirationDate have been granted.
-- This is the 27 exemptions that exists 2012-10-26.
-- If any new exemptions exist, add a new line where expirationDate is being updated to 6 months after dateCreated
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 2;
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 3;
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 4;
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 6;
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 7;
UPDATE `Exemption` SET `expirationDate` = '2012-08-21 00:00:00' WHERE `id` = 8;
UPDATE `Exemption` SET `expirationDate` = '2012-08-23 00:00:00' WHERE `id` = 9;
UPDATE `Exemption` SET `expirationDate` = '2012-08-26 00:00:00' WHERE `id` = 10;
UPDATE `Exemption` SET `expirationDate` = '2012-08-27 00:00:00' WHERE `id` = 11;
UPDATE `Exemption` SET `expirationDate` = '2012-08-28 00:00:00' WHERE `id` = 12;
UPDATE `Exemption` SET `expirationDate` = '2012-08-29 00:00:00' WHERE `id` = 13;
UPDATE `Exemption` SET `expirationDate` = '2012-09-01 00:00:00' WHERE `id` = 14;
UPDATE `Exemption` SET `expirationDate` = '2012-09-01 00:00:00' WHERE `id` = 15;
UPDATE `Exemption` SET `expirationDate` = '2012-09-02 00:00:00' WHERE `id` = 16;
UPDATE `Exemption` SET `expirationDate` = '2012-09-02 00:00:00' WHERE `id` = 17;
UPDATE `Exemption` SET `expirationDate` = '2012-09-02 00:00:00' WHERE `id` = 18;
UPDATE `Exemption` SET `expirationDate` = '2012-09-05 00:00:00' WHERE `id` = 19;
UPDATE `Exemption` SET `expirationDate` = '2012-09-05 00:00:00' WHERE `id` = 20;
UPDATE `Exemption` SET `expirationDate` = '2012-09-05 00:00:00' WHERE `id` = 21;
UPDATE `Exemption` SET `expirationDate` = '2012-09-05 00:00:00' WHERE `id` = 22;
UPDATE `Exemption` SET `expirationDate` = '2012-09-09 00:00:00' WHERE `id` = 23;
UPDATE `Exemption` SET `expirationDate` = '2012-09-14 00:00:00' WHERE `id` = 24;
UPDATE `Exemption` SET `expirationDate` = '2013-03-07 00:00:00' WHERE `id` = 25;
UPDATE `Exemption` SET `expirationDate` = '2013-03-12 00:00:00' WHERE `id` = 26;
UPDATE `Exemption` SET `expirationDate` = '2013-04-15 00:00:00' WHERE `id` = 27;
UPDATE `Exemption` SET `expirationDate` = '2013-04-16 00:00:00' WHERE `id` = 28;
UPDATE `Exemption` SET `expirationDate` = '2013-04-16 00:00:00' WHERE `id` = 29;

ALTER TABLE `project_class_settings`
  DROP `maxFinalSeminarActiveParticipation`,
  DROP `maxOpponentsOnFinalSeminar`,
  DROP `maxRegisterAsOpponent`;