From b42c3d60ed723698e9b94a5ecdaf66cd57986d46 Mon Sep 17 00:00:00 2001 From: songchenxuan Date: Thu, 29 Jun 2023 17:26:34 +0800 Subject: [PATCH] * Resolve MySQL GTID consistency violation error 1786, the same commit id is b0ae3d00c54ed5f845086b1a4d62e4c89cd1aa71. --- db/update18.3.sql | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/db/update18.3.sql b/db/update18.3.sql index fc25508a59..80be1ebdd5 100644 --- a/db/update18.3.sql +++ b/db/update18.3.sql @@ -214,7 +214,9 @@ CREATE TABLE IF NOT EXISTS `zt_privrelation` ( UNIQUE KEY `privrelation`(`priv`, `type`, `relationPriv`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; -CREATE TABLE `zt_chart_back` SELECT * FROM `zt_chart`; +-- 'CREATE TABLE `zt_chart_back` SELECT * FROM `zt_chart`;' will raise MySQL GTID consistency violation error. +CREATE TABLE `zt_chart_back` LIKE `zt_chart`; +INSERT INTO `zt_chart_back` SELECT * FROM `zt_chart`; ALTER TABLE `zt_chart` MODIFY `fields` mediumtext NULL; ALTER TABLE `zt_chart` MODIFY `group` varchar(255) NOT NULL;