flink-cdc icon indicating copy to clipboard operation
flink-cdc copied to clipboard

[Bug] DBZ-5589 Mysql connector can't handle the case sensitive of rename/change column statement

Open dua01 opened this issue 2 years ago • 1 comments

Search before asking

  • [X] I searched in the issues and found nothing similar.

Flink version

ALL

Flink CDC version

ALL

Database and its version

MySQL, ALL version

Minimal reproduce step

  1. create a table and write some data;
  2. listen it‘s binlog Source:mysql , Sink:print;
  3. alter a column case and update data.

What did you expect to see?

when i modify a clumn case, the filed name in the binlog record should be changed.

What did you see instead?

I changed a field name to lowercase, but its field name in binlog is still uppercase.

Anything else?

its a bug of debezium. source code in debezium-connector-mysql/src/main/java/io/debezium/connector/mysql/antlr/listener/AlterTableParserListener.java:AlterTableParserListener.java Debezium 2.0.0 fix it by modify line 187 and line 349. Use equals insdead of equalsIgnoreCase method. alter_clumn_test

Are you willing to submit a PR?

  • [x] I'm willing to submit a PR!

dua01 avatar May 18 '23 03:05 dua01

Would you like to cherry pick the bug fix to the cdc connector?

ruanhang1993 avatar Feb 04 '24 12:02 ruanhang1993

Closing this issue as it has been migrated to Apache Jira.

PatrickRen avatar Apr 09 '24 06:04 PatrickRen