8 lines
496 B
MySQL
8 lines
496 B
MySQL
|
ALTER TABLE `vn`.`entryLog`
|
||
|
CHANGE COLUMN `changedModel` `changedModel` ENUM('Entry', 'Buy', 'EntryObservation') NOT NULL DEFAULT 'Entry' ,
|
||
|
MODIFY COLUMN changedModelId INT(11) NOT NULL,
|
||
|
MODIFY COLUMN oldInstance JSON NULL,
|
||
|
MODIFY COLUMN newInstance JSON NULL,
|
||
|
ADD INDEX IF NOT EXISTS `entryLog_changedModel` (`changedModel` ASC, `changedModelId` ASC, `creationDate` ASC),
|
||
|
ADD INDEX IF NOT EXISTS `entryLog_originFk` (`originFk` ASC, `creationDate` ASC),
|
||
|
DROP INDEX IF EXISTS `logEntry_ibfk_1` ;
|