Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MySQL ALTER ADD COLUMN decimal type along with comment make parse DDL incorrect #987

Closed
an-vt opened this issue Feb 6, 2025 · 3 comments
Assignees

Comments

@an-vt
Copy link

an-vt commented Feb 6, 2025

When alter add a new column decimal type along comment make parse DDL get precision and scale for decimal type error

Reproduction

  1. Start replication.
  2. Run ALTER TABLE test ADD decimal_column DECIMAL(10,2) NOT NULL DEFAULT 0.00 COMMENT 'comment decimal column' on MySQL.
  3. Clickhouse execute DDL error

DDL error log:

Image

@an-vt an-vt changed the title MySQL ALTER ADD COLUMN decimal type along with comment make parse DDL error MySQL ALTER ADD COLUMN decimal type along with comment make parse DDL incorrect Feb 6, 2025
@aadant
Copy link
Collaborator

aadant commented Feb 24, 2025

that's a DDL parsing issue. @subkanthi this should be caught by comprehensive QA tests.

@aadant
Copy link
Collaborator

aadant commented Feb 24, 2025

this works fine, the comment confuses the parser

ALTER TABLE test ADD decimal_column DECIMAL(10,2) NOT NULL DEFAULT 0.0

@aadant
Copy link
Collaborator

aadant commented Feb 24, 2025

Most likely a duplicate of this bug #866, fixed in 2.6.0.

@aadant aadant closed this as completed Feb 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants