ALTER TABLE `vn`.`ticket` 
ADD COLUMN `zonePrice` DECIMAL(10,2) NULL DEFAULT NULL AFTER `collectionFk`,
ADD COLUMN `zoneBonus` DECIMAL(10,2) NULL DEFAULT NULL AFTER `zonePrice`,
ADD COLUMN `zoneClosure` TIME NULL AFTER `zoneBonus`;

CREATE TABLE vn.`zoneCalcTicket` (
  `zoneFk` int(11) NOT NULL PRIMARY KEY,
  CONSTRAINT `zoneCalcTicketfk_1` FOREIGN KEY (`zoneFk`) REFERENCES `zone` (`id`) ON DELETE CASCADE ON UPDATE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

DROP EVENT IF EXISTS vn.`zone_doCalc`; 
CREATE DEFINER=`root`@`%` EVENT vn.`zone_doCalc` 
    ON SCHEDULE EVERY 15 SECOND STARTS '2020-01-31 11:32:30' 
    ON COMPLETION PRESERVE ENABLE 
  DO CALL util.procNoOverlap('vn.zone_doCalc');

DROP TABLE `vn`.`zoneConfig`;

DROP procedure IF EXISTS vn.`zoneClosure_recalc`;