Skip to content
This repository has been archived by the owner on Nov 24, 2023. It is now read-only.

should split DDL for ADD COLUMN (c1 int, c2 int) #1339

Closed
lance6716 opened this issue Dec 15, 2020 · 2 comments · Fixed by #1340
Closed

should split DDL for ADD COLUMN (c1 int, c2 int) #1339

lance6716 opened this issue Dec 15, 2020 · 2 comments · Fixed by #1340
Labels
severity/major type/bug This issue is a bug report

Comments

@lance6716
Copy link
Collaborator

lance6716 commented Dec 15, 2020

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do? If possible, provide a recipe for reproducing the error.

in upstream.

ALTER TABLE `all_mode`.`t1` ADD COLUMN (`t6` INT, `t7` INT)
  1. What did you expect to see?

sync to downstream, split same as

alter table t1 add column t6 int, add column t7 int;
  1. What did you see instead?

                                "Message": "startLocation: [position: (mysql-bin.000001, 1902), gtid-set: 09bec856-ba95-11ea-850a-58f2b4af5188:1-8], endLocation: [position: (mysql-bin.000001, 2026), gtid-set: ]: execute statement failed: ALTER TABLE `all_mode`.`t1` ADD COLUMN (`t6` INT, `t7` INT)",
                                "RawCause": "Error 8200: Unsupported multi schema change",
  1. Versions of the cluster

    • DM version (run dmctl -V or dm-worker -V or dm-master -V):

      master

@csuzhangxc
Copy link
Member

alter table t1 add column t6 int, add column t7 int; should have been split to

alter table t1 add column t6 int;
alter table t1 add column t7 int;

but not split ALTER TABLE `all_mode`.`t1` ADD COLUMN (`t6` INT, `t7` INT), right?

@lance6716
Copy link
Collaborator Author

alter table t1 add column t6 int, add column t7 int; should have been split to

alter table t1 add column t6 int;
alter table t1 add column t7 int;

but not split ALTER TABLE `all_mode`.`t1` ADD COLUMN (`t6` INT, `t7` INT), right?

Yes. I think DM should split ADD COLUMN (xx, xx) same way as ADD COLUMN xx, ADD COLUMN xx

@lance6716 lance6716 changed the title didn't split DDL for ADD COLUMN (c1 int, c2 int) should split DDL for ADD COLUMN (c1 int, c2 int) Dec 15, 2020
@jebter jebter added severity/major type/bug This issue is a bug report labels Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
severity/major type/bug This issue is a bug report
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants