ALTER TABLE vn.ticket ADD cmrFk int(11) DEFAULT NULL NULL; ALTER TABLE vn.ticket ADD CONSTRAINT ticket_cmrFk FOREIGN KEY (cmrFk) REFERENCES vn.cmr(id) ON DELETE CASCADE ON UPDATE CASCADE; ALTER TABLE vn.ticket CHANGE cmrFk cmrFk int(11) DEFAULT NULL NULL AFTER clonedFrom; ALTER TABLE vn.cmr MODIFY COLUMN ticketFk int(11) DEFAULT NULL NULL COMMENT 'refs #6092 @toDeprecate 2023-08-02';